18F / domain-scan

A lightweight pipeline, locally or in Lambda, for scanning things like HTTPS, third party service use, and web accessibility.
Other
370 stars 137 forks source link

lambda: public-suffix-list.txt not found #268

Open robbi5 opened 6 years ago

robbi5 commented 6 years ago
[Errno 2] No such file or directory: './cache/public-suffix-list.txt': FileNotFoundError Traceback (most recent call last): File "/var/task/lambda_handler.py", line 29, in handler data = scanner.scan(domain, environment, options) File "/var/task/scanners/pshtt.py", line 79, in scan suffix_list = codecs.open(lambda_suffix_path, encoding='utf-8') File "/var/lang/lib/python3.6/codecs.py
[Errno 2] No such file or directory: './cache/public-suffix-list.txt': FileNotFoundError
Traceback (most recent call last):
File "/var/task/lambda_handler.py", line 29, in handler
data = scanner.scan(domain, environment, options)
File "/var/task/scanners/pshtt.py", line 79, in scan
suffix_list = codecs.open(lambda_suffix_path, encoding='utf-8')
File "/var/lang/lib/python3.6/codecs.py", line 895, in open
file = builtins.open(filename, mode, buffering)
FileNotFoundError: [Errno 2] No such file or directory: './cache/public-suffix-list.txt'

In #234 the public-suffix-list.txt moved to cache/public-suffix-list.txt. https://github.com/18F/domain-scan/blob/master/lambda/remote_build.sh#L64-L65 stores the file in the root - instead of the cache dir. Should this be changed, too?

konklone commented 6 years ago

I think that's right. Would you have things set up to test it and submit a PR? If not, it may be a bit until I can get to this.