Hello. I am trying to register on the site http://flymer.ru/signup using Jsoup in Java

Results of registration through the browser: Results of registration through the browser

What I do:

Connection.Response loginForm = Jsoup.connect("сайт.ру/signup") .userAgent("Mozilla/5.0").execute();

  document = Jsoup.connect("сайт.ру/signup") .userAgent("Mozilla/5.0") .data("email", mail) .data("pass", password) .data("agree","1") .cookies(loginForm.cookies()). post(); 

And, of course, nothing happens.
Judging by the Form Data, it is necessary to transfer also third-party values, and if I managed to parse fkey and skey and take it from the html-page, then what about the rest? And where does ts come from. Or am I not thinking there at all?

PS site.ru - due to the inability to write more than one link

    1 answer 1

    I received an answer to my question - without the Headless browser this is impossible to do.

    • Are there any scripts running? - gil9red 4:03
    • I wrote a script on python and tried to log in - pastebin.com/pFtZax0C works and a confirmation is sent to the specified email. You need to repeat the post request, passing it the data from the form and must roll - gil9red
    • @ gil9red; Yes, there on the javascript page handles the request. And, by the way, I also received the same answer, but the login / registration did not take place. In Python, Javascript is apparently executed upon request, but in java it is notyoulovejohnny
    • there is no javascript run, just use http, they are not used to register scripts. Open the developer panel of the browser, go to the network tab, register and see what request the browser sends and repeat it - gil9red
    • @gil9red that's exactly what I did (screenshot in the thread). Look at the data that the form transmits - you do not transfer them all in your code, but the registration with you passes, they automatically appear in your place. Robobrowser is in the list of Headless browser with support for js, without which, as I said, can not do - youlovejohnny