identifying attacker IP in WAF overview.

0

Hi,

We have recently implemented a WAF rule for our load balancer. We can see both the access logs for allowed and blocked requests in the overview section. My question is, is there a way to view the top 5 or top 10 offending IP addresses in real-time? Alternatively, what is the best approach to identify the attacker using WAF? like we use iftop and other utilities to identify the most offending IP traffic. any help is highly appreciated.

Thanks, Yousuf

2개 답변
2

Hello,

let me try to decompress your questions.

We can see both the access logs for allowed and blocked requests in the overview section Here I assume you are referring to the Sampled Requests? If so they are not real-time data and only contain a limited set of samples from the last 3 hours. https://docs.aws.amazon.com/waf/latest/developerguide/web-acl-testing-view-sample.html

is there a way to view the top 5 or top 10 offending IP addresses in real-time? Yes but to my knowledge not out of the box. You will first need to sent the logs to either S3 or CloudWatch Logs. If you send your logs to S3 (lower cost) you can then use AWS Athena to query the logs. To do so you will need to create a table as instructed here: https://docs.aws.amazon.com/athena/latest/ug/waf-logs.html you could then have a query to filter the offending IPs. This could be automated with a Lambda to run the top IPs query frequently. Another option would be to send the logs to CloudWatch logs and perform the analysis with Contributor Insights -> https://aws.amazon.com/blogs/mt/analyzing-aws-waf-logs-in-amazon-cloudwatch-logs/

what is the best approach to identify the attacker using WAF? I personally have Sampled Requests enabled for a quick overview, then Logs sent to S3 and an Athena table ready to be queried. I run SQL queries against the table to identify what is getting blocked or if a suspicious pattern is being allowed. But I know there are more sophisticated ways to do it like the example here: https://aws.amazon.com/blogs/security/automatically-updating-aws-waf-rule-in-real-time-using-amazon-eventbridge/

Hope it helps you a bit. Thanks.

profile picture
답변함 일 년 전
1
수락된 답변

What about enabling AWS WAF logs and analyzing them with Athena?
Also, visualization using QuickSight would be useful.
https://docs.aws.amazon.com/athena/latest/ug/waf-logs.html

The following document, which is in Japanese, introduces the analysis of WAF logs with QuickSight.
https://aws.amazon.com/jp/blogs/news/analyzing-aws-waf-logs-with-amazon-es-amazon-athena-and-amazon-quicksight/

profile picture
전문가
답변함 일 년 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠