??? ???????? ?? ??? Cloudflare ?????????? ?? ???????? ??? ?? ???? ?? ????

Rajinder Singh
Deep Learning Researcher
27-Sep-2024

???????????? ?? ?????????? ?????? ??? ?????? ?? ??????? ??? ?? ??? ?? ?????????? ???? ???????? ???? ??? ?? ??????? ?????? ?? ??? ???, ?? ????????? ???? ?? ?? ??????? ?? ??? ?? ?????? ??? ???, ?????????????? ??? ?? ???????? ??????? ?? ??????? ?? ????? ???? ???????, ??? ??????? ?? ??? ?????????? ??????? ?? ???, ???? ???? ?????? ?? ????????? ???? ???? ?? ??? ???????????? ?????????? ?????? ?? ?? ???? ?????????? ???
?? ???? ???, ?? ??? ???????? ??? ???????????? ?????????? ?????? ?? ??????? ?? ????????? ?? ??? ??????? ?? ????? ??? ???????? ?? CapSolver ?? ????? ???? ???? ?????? ?? ???????? ???? ?? ??? ??????? ?? ????? ???????
???????????? ?????????? ?????? ???? ???
???????????? ?????????? ?????? ?? ???????? ????-??? ????? ??? ???????? ?????? ????????? ?? ??????, ??????? ???????????? ?? ????? ?? ???? ?? ?????? ?? ????? ???? ?? ???????? ???? ??, ?????????? ?????????? ????? ?? ????? ??? ???? ?? ????? ???? ?? ??? ?????? ??????? ???? ?? ????? ???? ?? ?? ??? ?????? ??? ?? ??? ?? ?? ???????? ?????????? ???
?? ?????? ?????????? ?????? ?? ?????? ?? ????? ???? ??:
- ?????????? ???????: ??? ?????? ?? ??? ???? ?? ???? ???? ??????? ?? ????? ???? ????
- ???? ?????????: ???? ??? ?? ??????, ?????? ????? ?? ?? ???? ??? ??????? ??????? ?? ??? ??????? ???? ??? ???
- ???????? ????????????: ???? ?? ??????? ?? ??? ????? ??? ?? ??? ???????? ?? ?????? ?? ???? ??? ????????
??? ?????? ?? ???????? ?? ???, ?????????? ?????? ???? ????????? ?? ???? ??? ???? ???? ?? ??? ???? ??? ???????????? ???????? ???? ???? ?? ???, ???? ?? ?????? ?? ?? ???? ?? ????????? ?? ???????? ???? ?? ???????? ?????
???? ???
????? ?????? ???????? ?? ??? ???? ???? ??? ????? ????; CapSolver: WEBS. ??? ????? ???? ?? ???, ???? ???????? ??????? ?? ??? 5% ???????? ???? ??????, ??????
??? ?????? ?? ??? ?????????
???????????? ?????????? ?????? ?? ???? ??????? ??????? ???????? ?? ????? ????? ???? ?? ??? ??????? ???? ??? ??? ??? ???????? ????? ???????? ??????? ?? ??????? ?? ?????? ???? ??? ?? ?????? ?? ????? ???? ???, ????? ???????????? ????? ?? ????? ?? ????? ???? ?????? ???? ??? ???? ?????? ?? ?????????? ?? ??? ?? ?????? ?? ???????? ??? ?? ?? ???? ???? ???? ??, ????? ??????? ?????????? ?? ???? ???
???????????? ?????????? ?????? ?? ?? ???? ?? ??? ?? ??????? ????????? ??? ????? ???:
- ???? ???? ????????? ?? ?????? ?????? ?? ?????? ???? ?? ???? ?? ????
- ?????? ?? ???? ????? ???????? ?? ?????? ?? ???? ??? ???????
- ?????-???? ??????-?????? ?????? ?? ????? ???? ????????? ?? ?? ???? ?? ??? ?? ?? ????? ???? ????
??? ?? ??????? ?? ??? ????? ????? ????? ?? ??? ??????? ???? ?? ??? ?? ???? ????
???????????? ?????????? ?????? ?? ???????? ???? ?? ??? ????? ?? ?????????
???? ??? ?????? ??? ???????????? ?????????? ?????? ?? ?? ???? ?? ???, ???? ?????????? ???, ???????? ?? ??????-?????? ?????? ?? ?????? ?? ???????? ????? ???? ?? ????? ??:
-
??? ?????????? ?????????:
- Selenium, Puppeteer, ?? Playwright ???? ????? ????? ?? ???????? ?? ???????? ???? ?? ??? ????? ?? ??? ?????? ???? ?? ??? ????? ??? ???? ???? ?? ???? ?????????????-???? ?????? ?? ??????? ?? ???????? ??? ????? ?????? ?? ?????? ?? ?????? ???? ????
- ????????, ????? ??? ??, ?? Node.js ????????? ?? ?? ????? ?? ???????? ???????? ?? ????????? ???? ?? ??? ???? ?????? API ?????? ???? ??? ?? ????? ??? ?? ?????????? ??????? ??? ???????? ?????? ?? ??????? ?? ??? ????? ??, ????? ?? ?????? ?? ?????? ????? ???
-
????????:
- ??????? ???????????? ?? ?????? ???? ?? ???? ???????? ?? ????????? ?? ????? ?? ??? ?????? ?? ????? ???? ???????? ?????? ???? ???????? ?????????? ???? ????-??? ?????? ?? ?????? ???? ?? ???? ?? ??? ?? ???? ?? ???????? ?? ?????? ???? ??? ??? ???? ????
- ????? ???? ???????? ???????? ?????? ?? ??? ?????? ??? ?? ?? ??? ???? ????? ???? ???, ????? ???????????? ?? ??? ?????????? ??????? ??? ?????? ?? ????? ???? ???? ?? ???? ???
-
??????-?????? ??????:
- CapSolver ???? ?????? ?????? ????????? ?? ???????? ??? ?? ?? ???? ?? ??? ??????? ?? ?? ???? ?? ?????? ??? ?????????? ??? ?? ??? ?????? ???? ??? ?? ???????? ????????? ?? ???? ?????? ?? ??????? ???? ?? ??? ?????? ???? ?????? ???? ???? ???? ??? ???????????? ?????????? ?????? ?? ?? ?? ???? ????
???????? ?? ????????? ?? ??? ???????????? ?????????? ?????? ?? ???? ?? ????
?? ?????? ???, ?? ????????? ?????? ?? ???????? ?? ????????? ?? ????? ???? ???????????? ?????????? ?????? ?? ???? ?? ?????
????? ??????
????????? ???? ?? ???? ?????????? ??????? ??? ???:
- ????????:
npm install puppeteer
- ???????:
npm install axios
(API ?????? ???? ?? ???)
???-??-??? ????????????
javascript
const puppeteer = require('puppeteer');
const axios = require('axios');
const clientKey = 'your-client-key-here'; // ???? CapSolver ??????? ????? ?? ?????
const websiteURL = 'https://example.com'; // ???? ?????? ??????? URL ?? ?????
const websiteKey = 'your-site-key-here'; // ?????? ??????? ?? ???? ????? ?? ?????
// ?????????? ?????? ?? ?? ???? ?? ??? ?? ????? ????? ?? ???????
async function createTask() {
const response = await axios.post('https://api.capsolver.com/createTask', {
clientKey: clientKey,
task: {
type: "AntiTurnstileTaskProxyLess",
websiteURL: websiteURL,
websiteKey: websiteKey
}
}, {
headers: {
'Content-Type': 'application/json',
'Pragma': 'no-cache'
}
});
return response.data.taskId;
}
// ????? ?????? ??????? ???? ?? ???????
async function getTaskResult(taskId) {
let response;
while (true) {
response = await axios.post('https://api.capsolver.com/getTaskResult', {
clientKey: clientKey,
taskId: taskId
}, {
headers: {
'Content-Type': 'application/json'
}
});
if (response.data.status === 'ready') {
return response.data.solution;
}
console.log('Solution not ready yet, checking again in 5 seconds...');
await new Promise(resolve => setTimeout(resolve, 5000));
}
}
// ?????????? ?? ?????? ?? ?? ???? ?? ??? ????? ???????? ?????????
(async () => {
const taskId = await createTask();
const result = await getTaskResult(taskId);
let solution = result.token;
const browser = await puppeteer.launch({ headless: false });
const page = await browser.newPage();
await page.goto(websiteURL);
await page.waitForSelector('input[name="cf-turnstile-response"]');
// ?????? ?????? ???? ?? ?????? ??? ?????
await page.evaluate(solution => {
document.querySelector('input[name="cf-turnstile-response"]').value = solution;
}, solution);
// ??????? ?????????? ?? ??? ????? ?? ?????????? ???
await page.screenshot({ path: 'example.png' });
await browser.close();
})();
?????????? ?? ??? ??? ?????????? ??????? ??? ????
???? ???? ?????? ?? ?????? ?????????? ????????? ???? ?? ???, ?? ????? ??? ?? ????????? ???? ??? ??????? ???? ?????????? ??:
-
?????? ????????: ???? ??????? ?? ?????? ???? ??? ????? ???? ??? Puppeteer ?? Playwright ???? ?????? ???????? ?? ????? ????? ?? ????? ????????????? ????????, ?????? ?????? ?? ?????? ??????? ?? ????? ???? ????
-
???????? ??????: ????? ???? ?? ???? ?? ??? ???????? ?????? ???? ????? ?????? ???????? ???? ????? ???? ?? ????? ??? ?? ??????? ???? ?? ??????? ??? ?? ????????? ???????? ?????? ?? ??? IPRoyal ???? ???????? ????????? ?? ?? ?????? ?? ???? ????
-
???? ???????: ???-??? ??? ?? ???? ?? ??????? ????? ?? ?????? ???? ?? ????? ???? ???? ?? ???? ?? ??? ?? ???? ?? ???????? ?????? ?? ???? ???? ?? ???: ????? ?????
-
?????? ??????: CapSolver ???? ??????-?????? ?????? ?? ??? ????? ???? ?????? ????????? ?? ?? ???? ?? ???? ?? ?????? API ?????? ???? ??? ?? ????? ?? ???? ??????-?????? ?? ??????? ???, ????? ???? ???????? ?? ???? ????????? ???? ???? ?? ?????? ????? ???
????????
???????????? ?????????? ?????? ?? ?? ???? ??? ??? ???????? ??????? ?? ??? ?????? ?? ??????? ???? ?? ??????? ????? ?? ???????? ???? ??? ????????, ???????? ?? ?????-???? ?????? ?????? ???? ????????? ???? ??? ??????? ????????? ?? ?????? ?? ?? ?????? ?? ??????? ??? ?? ??? ?? ???? ???? ??? ??????? ?? ????????? ?? ???, ???? ???????? ???????? ????????? ?? ???? ???????????? ???? ????? ???? ???? ?? ???? ???
??????? ?? ???
??????????: ??? ?????????? ??? ?????? ???? ??, ?????? ?? ????? ????????????? ?? ???? ???? ?????????? ??? ????? ????????? ???? ?? ???? ?????? ??????? ?? ??????? ???? ?? ?????? ??, ?? ???? ??
robots.txt
????? ?? ???? ?? ?????? ?? ?????? ????? CapSolver ???? ?? ???-??????? ?????????? ?? ??? ???? ?????? ?? ???????? ?? ?????? ?? ????? ???? ??? ???? ???? ????????? ?? ???????? ??????? ?? ???????? ?? ?????? ?? ??????? ???? ?????? ?????? ?? ???? ??? ??????? ???????? ?? ???? ?? ??? ????????? ???? ?? ???? ?????????? ?????????? ??? ???? ??????? ?? ?????? ?? ??????? ??? ????
??????? ????????: ?? ????? ?? ?????? ?? ?? ??????? ???? ????????? ?????????? ?? ??? ??? CapSolver ??? ???? ??????? ?? ???????? ?? ???? ???? ?? ??? ????????? ??? CapSolver ??????? ?? ????? ????, ???????? ?? ???????? ???? ???? ?????????? ?? ??? ???? ???? ?????? ?? ?? ???? ???? ?? ?????? ????? ?????? ?????? ?????????? ????? ?? ????? ????? ?? ???-??? ????????? ???? ???????? ?? ????? ?????? ????????? ?? ?? ???? ??? 100% ??????? ????????? ???? ???? ?? ???? ?????? ?? ????????? ????? ?? ??????????? ???? ???? ???? ??????? ?? ???, ????? ????? ???? ?? ?????? ?? ???????? ???? ?? ?????
????

Cloudflare TLS ???????????????: ?? ???? ?? ?? ??? ???? ?? ????
Cloudflare ?????? ??????? ?? ??? TLS ??????????????? ?? ?????, ????? ?? ??? ????? ?? ?????? ????? ???? ?? ?????, ?? ??? ?????????? ?? ???????? ?????????? ??????? ?? ??? ??? ?? ???? ?? ??????? ?????? ?? ???? ??? ??????

Rajinder Singh
28-Feb-2025

Cloudflare ?? ???????? ??????? ?? ???? ???? ???????
?? ???? ???, ?? Cloudflare ?? ???????? ????????? ?? ???? ??????? ?? ????? ?? ??????? ?????? ?? ??? ????????

Rajinder Singh
20-Feb-2025

2025 ??? Python ?? Go ?? ????? ???? Cloudflare ?? ???? ?? ????
Cloudflare Turnstile ???? ??, ???? ???? ??? ??????? ???? ??????, ?? ??????? ?? ??? Python ?? Go ?? ????? ??????, ???? Turnstile Python ???????? ?? ??? ??? ???? ??, ?? CapSolver ???? ???????? ?? ????? ???? ??? ??????? ??? ?? ???? ?????? ?????

Rajinder Singh
05-Nov-2024

Selenium ?? ????? ???? Cloudflare Turnstile Captchas ?? ???? ?? ????
?? ????? ???, ?? ???????? ?? ????? ???? Cloudflare Turnstile Captchas ?? ??? ???? ?? ??? ?? ??????? ??????? ?? ????? ???????

Rajinder Singh
11-Oct-2024

??? ???????? ?? ??? Cloudflare ?????????? ?? ???????? ??? ?? ???? ?? ????
?? ??? ???????? ??? Cloudflare Turnstile CAPTCHA ?? ??????? ?? ????????? ?? ??? ??????? ?? ????? ??? Puppeteer ?? CapSolver ?? ????? ???? ???? ?????? ?? ???????? ???? ?? ??????? ?? ????? ???????

Rajinder Singh
27-Sep-2024

C# ?? ????? ???? Cloudflare Turnstile CAPTCHA ????????? ?? ???? ?? ????
?? C# ?? ????? ???? Cloudflare Turnstile ?? CAPTCHA ?????? ?? ????? ?? ???? ?? ??????, ?? ??????? ????? ????? ???? ??? ???? ???!

Rajinder Singh
17-Sep-2024