Detect DDoS-Guard challenge

This commit is contained in:
ngosang
2022-04-17 09:21:10 +02:00
parent 93d8350097
commit d962e1a14e
3 changed files with 7 additions and 6 deletions

View File

@@ -15,7 +15,7 @@ const postUrl = "https://ptsv2.com/t/qv4j3-1634496523";
const cfUrl = "https://pirateiro.com/torrents/?search=harry";
const cfCaptchaUrl = "https://idope.se"
const cfBlockedUrl = "https://www.torrentmafya.org/table.php"
const ddgUrl = "https://www.erai-raws.info/feed/?type=magnet";
const ddgUrl = "https://anidex.info/";
const ccfUrl = "https://www.muziekfabriek.org";
beforeAll(async () => {
@@ -189,12 +189,12 @@ describe("Test '/v1' path", () => {
expect(solution.url).toContain(ddgUrl)
expect(solution.status).toBe(200);
expect(Object.keys(solution.headers).length).toBeGreaterThan(0)
expect(solution.response).toContain("<rss version")
expect(solution.response).toContain("<!DOCTYPE html>")
expect(Object.keys(solution.cookies).length).toBeGreaterThan(0)
expect(solution.userAgent).toContain("Firefox/")
const cfCookie: string = (solution.cookies as any[]).filter(function(cookie) {
return cookie.name == "__ddg1";
return cookie.name == "__ddg1_";
})[0].value
expect(cfCookie.length).toBeGreaterThan(10)
});