Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
@antiadmin/anticaptchaofficial
Advanced tools
Official anti-captcha.com npm package for solving images with text, Recaptcha v2/v3 Enterprise/non-Enterpise, Funcaptcha, GeeTest, HCaptcha Enterprise/non-Enterprise.
Anti-captcha is an oldest and cheapest web service dedicated to solving captchas by human workers from around the world. By solving captchas with us you help people in poorest regions of the world to earn money, which not only cover their basic needs, but also gives them ability to financially help their families, study and avoid jobs where they're simply not happy.
To use the service you need to register and topup your balance. Prices start from $0.0005 per image captcha and $0.002 for Recaptcha. That's $0.5 per 1000 for images and $2 for 1000 Recaptchas.
For more technical information and articles visit our documentation page.
Module installation:
npm install @antiadmin/anticaptchaofficial
Import and check your balance in sync mode:
(async() => {
const ac = require("@antiadmin/anticaptchaofficial");
ac.setAPIKey('YOUR_API_KEY');
try {
const balance = await ac.getBalance();
console.log(`my balance is $${balance}`);
if (balance <= 0) {
throw "negative balance"
}
console.log("solving a captcha..")
// const token = await ac.solveRecaptchaV2Proxyless('http://DOMAIN.COM', 'WEBSITE_KEY');
// const fs = require('fs');
// const text = await ac.solveImage(fs.readFileSync('captcha.png', { encoding: 'base64' }), true)
} catch (e) {
console.log("got error: ", e.toString());
}
})();
Or do the same with promises:
const ac = require("@antiadmin/anticaptchaofficial");
ac.setAPIKey('YOUR_API_KEY');
ac.getBalance()
.then(balance => {
console.log('my balance is $' + balance)
if (balance <= 0) {
return false;
}
console.log("solving a captcha..")
// ac.solveRecaptchaV2Proxyless('http://DOMAIN.COM', 'WEBSITE_KEY')
// .then(token => {
// console.log('Got g-response:', token)
// // do something
// })
// .catch(error => {
// console.log('test received error ' + error)
// return false;
// });
})
.catch(error => console.log('received error '+error))
Disable verbose output to console:
ac.shutUp();
Specify softId to earn 10% commission from all captcha spendings with your app. Get your softId in Developers Center.
ac.setSoftId(SOFT_ID_NUMBER);
Solve Recaptcha V2 without proxy:
ac.settings.recaptchaDataSValue = 'set me for google.com domains';
const gresponse = ac.solveRecaptchaV2Proxyless('http://DOMAIN.COM', 'WEBSITE_KEY');
console.log('g-response: '+gresponse);
console.log('google cookies:');
console.log(ac.getCookies());
Learn what to do with g-response in this article.
Report last solved Recaptcha v2/v3 as incorrect (must read this before using):
await ac.reportIncorrectRecaptcha();
Report Recaptcha v3 as correctly solved (more info here before using):
await ac.reportCorrectRecaptcha();
Solve Recaptcha V2 with proxy:
const gresponse = await ac.solveRecaptchaV2ProxyOn('http://DOMAIN.COM',
'WEBSITE_KEY',
'http', //http, socks4, socks5
'PROXY_IP',
'PROXY_PORT',
'PROXY_LOGIN',
'PROXY_PASSWORD',
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116',
'some=cookies');
Solve Recaptcha V2-invisible (note the 3rd parameter "true"):
const gresponse = await ac.solveRecaptchaV2Proxyless('http://DOMAIN.COM', 'WEBSITE_KEY', true)
Solve Recaptcha V3:
const gresponse = await ac.solveRecaptchaV3('http://DOMAIN.COM',
'WEBSITE_KEY',
0.3, //minimum score required: 0.3, 0.7 or 0.9
'PAGE_ACTION_CAN_BE_EMPTY');
Solve Recaptcha V2 Enterprise without proxy:
const gresponse = await ac.solveRecaptchaV2EnterpriseProxyless(
'http://DOMAIN.COM',
'WEBSITE_KEY',
{ //enterprise payload:
"s" : "SOME_TOKEN",
"custom_parameter" : "string_number_boolean"
});
Solve HCaptcha without proxy:
const token = await ac.solveHCaptchaProxyless('http://DOMAIN.COM', 'WEBSITE_KEY', 'FULL USER AGENT HERE');
const userAgent = ac.getHcaptchaUserAgent();
// use this userAgent for posting the form with token!
Report last solved Hcaptcha as incorrect:
await ac.reportIncorrectHcaptcha();
Solve HCaptcha Enterprise without proxy:
const token = await ac.solveHCaptchaProxyless('http://DOMAIN.COM',
'WEBSITE_KEY',
'FULL USER AGENT HERE',
{
'rqdata': 'rqdata from target website',
'sentry': true,
// set here parameters like rqdata, sentry, apiEndpoint, endpoint, reportapi, assethost, imghost
// for more info go to https://anti-captcha.com/apidoc/task-types/HCaptchaTaskProxyless
});
const userAgent = ac.getHcaptchaUserAgent();
// use this userAgent for posting the form with token!
Solve HCaptcha Enterprise with proxy:
const token = await ac.solveHCaptchaProxyless('http://DOMAIN.COM',
'WEBSITE_KEY',
'FULL USER AGENT HERE',
'http',
'1.2.3.4',
3128,
'proxy-login',
'proxy-password',
'',
'',
{
'rqdata': 'rqdata from target website',
'sentry': true,
// set here parameters like rqdata, sentry, apiEndpoint, endpoint, reportapi, assethost, imghost
// for more info go to https://anti-captcha.com/apidoc/task-types/HCaptchaTaskProxyless
});
const userAgent = ac.getHcaptchaUserAgent();
// use this userAgent for posting the form with token!
Solve Turnstile without proxy:
const token = await ac.solveTurnstileProxyless('http://DOMAIN.COM', 'WEBSITE_KEY', 'optional_action');
Solve Turnstile with proxy:
const token = await ac.solveTurnstileProxyOn('http://DOMAIN.COM',
'WEBSITE_KEY',
'http', //http, socks4, socks5
'PROXY_IP',
'PROXY_PORT',
'PROXY_LOGIN',
'PROXY_PASSWORD',
'optional_action');
Solve AntiGate Task:
const solution = await ac.solveAntiGateTask(
'http://antigate.com/logintest.php',
'Sign-in and wait for control text',
{
"login_input_css": "#login",
"login_input_value": "the login",
"password_input_css": "#password",
"password_input_value": "the password",
"control_text": "You have been logged successfully"
});
console.log('cookies: ', solution.cookies);
console.log('localStorage: ', solution.localStorage);
console.log('url: ', solution.url);
same with a proxy:
const solution = await ac.solveAntiGateTask(
'http://antigate.com/logintest.php',
'Sign-in and wait for control text',
{
"login_input_css": "#login",
"login_input_value": "the login",
"password_input_css": "#password",
"password_input_value": "the password",
"control_text": "You have been logged successfully"
},
'PROXY_IP',
'PROXY_PORT',
'PROXY_LOGIN',
'PROXY_PASSWORD');
Send a task with a delayed variable and push it after a few seconds:
const taskId = await ac.sendAntiGateTask('http://antigate.com/logintest2fa.php',
'Sign-in with 2FA and wait for control text',
{
"login_input_css": "#login",
"login_input_value": "the login",
"password_input_css": "#password",
"password_input_value": "the password",
"2fa_input_css": "#2facode",
"2fa_input_value": "_WAIT_FOR_IT_",
"control_text": "You have been logged successfully"
});
await ac.delay(5000); //simulate a delay in 2FA retrieval
await ac.pushAntiGateVariable('2fa_input_value', '349001');
const solution = await ac.waitForResult(taskId);
console.log('solution:');
console.log(solution);
Bypass Cloudflare / Datadome / etc. More info about this:
const solution = await ac.solveAntiBotCookieTask(
'https://www.thewebsite.com/',
'PROXY_IP',
'PROXY_PORT',
'PROXY_LOGIN',
'PROXY_PASSWORD');
Bypass Funcaptcha / Arkoselabs without proxy:
//optional data blob:
ac.settings.funcaptchaDataBlob = 'blob value here is any, or leave it empty';
const token = await ac.solveFunCaptchaProxyless(
'https://www.thewebsite.com/path',
'site-key');
Bypass Funcaptcha / Arkoselabs via proxy:
//optional data blob:
ac.settings.funcaptchaDataBlob = 'blob value here is any, or leave it empty';
const token = await ac.solveFunCaptchaProxyOn(
'https://www.thewebsite.com/path',
'site-key',
'http',
'1.2.3.4',
3128,
'proxy-login',
'proxy-password',
'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116',
'');
Bypass Geetest version 3 without proxy. See tutorial how to find these parameters.
const token = await ac.solveGeeTestProxyless(
'https://www.thewebsite.com/path',
'gt key 32 bytes',
'challenge value 32 bytes',
'optional.api-domain.com');
Bypass Geetest version 4 without proxy. See tutorial how to find these parameters.
const token = await ac.solveGeeTestV4Proxyless(
'https://www.thewebsite.com/path',
'captchaId key 32 bytes',
'optional.api-domain.com',
{
'riskType': 'slide' //example
});
Other available task types with similar method calls:
await ac.solveRecaptchaV2EnterpriseProxyOn( ... ); //Recaptcha V2 Enterprise with proxy
await ac.solveRecaptchaV3Enterprise( ... ); //Recaptcha V3 Enterprise
await ac.solveHCaptchaProxyOn( ... ); //hCaptcha with proxy
await ac.solveGeeTestProxyOn( ... ); //Solve Geetest with proxy
await ac.solveGeeTestV4ProxyOn( ... ); //Bypass Geetest V4 with proxy
FAQs
Official Anti-Captcha.com npm library
The npm package @antiadmin/anticaptchaofficial receives a total of 12,637 weekly downloads. As such, @antiadmin/anticaptchaofficial popularity was classified as popular.
We found that @antiadmin/anticaptchaofficial demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.