owasp-amass / amass

In-depth attack surface mapping and asset discovery
https://owasp.org/www-project-amass/
Other
11.78k stars 1.86k forks source link

Official Docker Container randomly crashes on AWS Fargate #905

Open falc410 opened 1 year ago

falc410 commented 1 year ago

I am running the official docker container caffix/amass:3.21.2 on AWS Fargate and mounting an EFS to store the output. The container basically receives a list of domains to query and write the output to the filesystem. This works 99% of the time but every once in a while the container will become unresponsive during the enum phase. I haven't been able to track down the problem yet, so any help would be appreciated. It happens about once a week and not always for the same domain, it seems random but does seem to happen more often for a domain with a lot of subdomains. There is no error message to be seen and the container is complete unresponsive. I can not connect with ECS exec to open a shell or anything. I implemented a healthcheck and AWS also lists the container as unhealthy. I usually only give it 2GB of RAM and from the container insights, this doesn't seem to be a problem. I tried with 4GB and it still crashed.

When running the container locally in docker, I never had any problems. Any idea and how to further debug this issue? As I saw in the other threads, some people had issues with earlier versions and amass creating too many threads. I suspect something similar going on, something that Fargate and docker doesn't like.