thalesgroup-cert / Watcher

Watcher - Open Source Cybersecurity Threat Hunting Platform. Developed with Django & React JS.
https://thalesgroup-cert.github.io/Watcher
GNU Affero General Public License v3.0
847 stars 122 forks source link

Add timeout to feed fetch request #89

Closed eciavatta closed 1 year ago

eciavatta commented 1 year ago

When the threats watcher cron runs it first download the contents of the feeds for each rss. The routine that download each feed is sequential. This is a problem when the connection used to download a feed hangs, because it blocks the entire process indefinitely.

To fix this, I added a 60 second timeout for each request.

Felix83000 commented 1 year ago

Thanks. You are right.

Merging your idea.