NEWStandard createTask and in.php APIs. Change the address and you are connected.View API docs
GATESOLVER

Glossary

AWS WAF CAPTCHA

AWS WAF CAPTCHA is the puzzle and challenge layer of Amazon Web Services' web application firewall, which ends in an aws-waf-token cookie the site checks on later requests.

Definition

AWS WAF is the firewall Amazon offers in front of CloudFront distributions, load balancers, API Gateway and similar services. Besides allowing or blocking, a rule can respond with two softer actions. Challenge runs a silent browser check, similar in spirit to a proof of work, and passes most real browsers without any interaction. CAPTCHA shows a visible puzzle, usually an image selection or audio task. Both end the same way: the browser receives an aws-waf-token cookie, and requests that carry a valid one are let through.

Because AWS WAF is a building block, you meet it on all kinds of sites, from retailers to ticketing to public sector portals, often without any AWS branding on the page.

How to recognise it

  • The response status is 405 for a CAPTCHA action or 202 for a challenge, with a short HTML body.
  • Scripts load from a domain ending in .token.awswaf.com or .captcha.awswaf.com, typically challenge.js or captcha.js.
  • The page script contains window.gokuProps with three fields: key, iv and context.
  • After a pass, the browser has a cookie named aws-waf-token.

The key, iv and context values

The gokuProps object holds the values the challenge script uses to build its answer. key identifies the protection configuration, while iv and context change per page load. When you send them with a task, the solver works from exactly the challenge your page received. In GateSolver tasks they map to awsKey, awsIv and awsContext. All three are optional because the solver can load the page itself, but passing fresh values from your own page load is often more reliable.

{"clientKey": "YOUR_API_KEY", "task": {"type": "AntiAwsWafTaskProxyLess",
  "websiteURL": "https://shop.example.com/search", "awsKey": "AQIDAHjcYu/GjX+QlghicBg...",
  "awsIv": "CgAHbCe2GgAAAAAj", "awsContext": "9BUgmlm48F92WUoqv97a..."}}

The solution contains a single cookie value. Set it as aws-waf-token on the target domain and repeat your request.

Token lifetime and binding

The site owner sets an immunity time, after which the token must be refreshed. AWS's default for CAPTCHA immunity is five minutes, and owners can raise it. Tokens can also be scoped to specific domains. If your later requests come from a very different client, the site may challenge again, so when you need a strict match, use the proxy variant AntiAwsWafTask and send traffic through the same proxy afterwards.

Image puzzles inside AWS WAF

When the CAPTCHA action shows an image grid ("choose all the beds", for example), there is a second route: solve the grid itself with the AWS WAF Image Classification task, which takes the images and the question and returns the indexes to pick. Most integrations prefer the cookie task, because it skips the browser work entirely. The image classification guide covers the grid case.

Cost and speed

The AWS WAF task costs $1.40 per 1,000 solved tasks and usually completes under 3 seconds. Unsolved tasks are free, and so is any request that returns an error. You can find the full field list in the API docs and a step by step version in finding AWS WAF parameters.

Practical tips

Read gokuProps from the same response you are trying to get past, not from an earlier visit, since iv and context rotate. Keep cookies in one jar per session so the token travels with the other cookies the site set. And when a site has only the silent challenge action, the same task still applies: it returns a working token without any image puzzle involved.

Common questions

What status code does an AWS WAF CAPTCHA return?

A CAPTCHA action usually answers with 405 and a challenge action with 202, each with a short HTML page that loads the AWS script.

Where do I find awsKey, awsIv and awsContext?

In the page script, inside the window.gokuProps object, under key, iv and context.

Do I have to send the gokuProps values?

No, they are optional, but fresh values from your own page load make the result match the challenge you actually received.

How long does aws-waf-token stay valid?

The site owner sets the immunity time; five minutes is a common default, and some sites allow longer.

Should I use the cookie task or image classification?

Prefer the cookie task for HTTP clients; use image classification when you drive a browser and need to click the right tiles.

Keep reading