Menu

Bypass Recaptcha on a form with a callback. Tutorial 2.


What you're going to learn

  • You will learn how to submit this form with Recaptcha with NodeJS script.
  • Learn the difference between a hidden textarea and a callback approach.
  • Learn how to properly search javascript 'grecaptcha.render' call.
Source code

This video highlights difference in approach from previous tutorial. Instead of pasting g-response token to the form's textarea, we invoke the "checkCaptcha" function which can be found in the page source code.

console.log('setting recaptcha g-response ...');
await tab.evaluate((token) => {
  checkCaptcha(token);
}, token);

There's also no need to push any submit buttons, as submission happens automatically after Recaptcha is solved.

console.log('submitting form .. ');
await Promise.all([
  tab.click('#contentbox > form > div > div.tac.padding20px > button'),
  tab.waitForNavigation({ waitUntil: "networkidle0" })
]);

In the next tutorial you'll learn how to bypass a form with Recaptcha where callback function is not separated from the gresponse.render call and its body is encrypted.

Github

https://github.com/anti-captcha/solving-captcha-concepts/blob/master/tutorial2.js