Block suspicious(specific) user-agent using AWS WAF


I want to block all requests with suspicious user-agent to access APIGW. For example, how can I make rule to block all requests with user-agent as


or other version of python-requests

1 Answer
Accepted Answer

The simplest way to do this is to create a string match condition and then check the User-Agent header against that condition.

profile pictureAWS
answered 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions