MISP / MISP

MISP (core software) - Open Source Threat Intelligence and Sharing Platform
https://www.misp-project.org/
GNU Affero General Public License v3.0
5.33k stars 1.39k forks source link

Bug: #9281

Closed federicobaldoni-nextegy closed 1 year ago

federicobaldoni-nextegy commented 1 year ago

Actual behavior

The fetch of the phishtank feed does not work and generates this error:

2023-09-11 10:59:21 Error: Could not get freetext feed 7
[HttpSocketHttpException] Remote server returns HTTP error code 404 for URL https://data.phishtank.com/data/online-valid.csv
Stack Trace:
#0 /var/www/MISP/app/Model/Feed.php(343): Feed->feedGetUriRemote()
#1 /var/www/MISP/app/Model/Feed.php(382): Feed->getFreetextFeedRemote()
#2 /var/www/MISP/app/Model/Feed.php(1187): Feed->getFreetextFeed()
#3 /var/www/MISP/app/Console/Command/ServerShell.php(388): Feed->downloadFromFeedInitiator()
#4 /var/www/MISP/app/Lib/cakephp/lib/Cake/Console/Shell.php(459): ServerShell->fetchFeed()
#5 /var/www/MISP/app/Lib/cakephp/lib/Cake/Console/ShellDispatcher.php(222): Shell->runCommand()
#6 /var/www/MISP/app/Lib/cakephp/lib/Cake/Console/ShellDispatcher.php(66): ShellDispatcher->dispatch()
#7 /var/www/MISP/app/Console/cake.php(45): ShellDispatcher::run()
#8 {main}

From the same server with curl or wget I get no errors

Expected behavior

Fetch of phishtank feed should complete without errors

Steps to reproduce

Enable phishtank feed and fetch it with the command: MISP/app/Console/cake Server fetchFeed 1 all

Version

2.4.175

Operating System

Ubuntu

Operating System version

20.04

PHP version

7.4.3-4ubuntu2.19

Browser

No response

Browser version

No response

Relevant log output

2023-09-11 10:59:21 Error: Could not get freetext feed 7
[HttpSocketHttpException] Remote server returns HTTP error code 404 for URL https://data.phishtank.com/data/online-valid.csv
Stack Trace:
#0 /var/www/MISP/app/Model/Feed.php(343): Feed->feedGetUriRemote()
#1 /var/www/MISP/app/Model/Feed.php(382): Feed->getFreetextFeedRemote()
#2 /var/www/MISP/app/Model/Feed.php(1187): Feed->getFreetextFeed()
#3 /var/www/MISP/app/Console/Command/ServerShell.php(388): Feed->downloadFromFeedInitiator()
#4 /var/www/MISP/app/Lib/cakephp/lib/Cake/Console/Shell.php(459): ServerShell->fetchFeed()
#5 /var/www/MISP/app/Lib/cakephp/lib/Cake/Console/ShellDispatcher.php(222): Shell->runCommand()
#6 /var/www/MISP/app/Lib/cakephp/lib/Cake/Console/ShellDispatcher.php(66): ShellDispatcher->dispatch()
#7 /var/www/MISP/app/Console/cake.php(45): ShellDispatcher::run()
#8 {main}


### Extra attachments

_No response_

### Code of Conduct

- [X] I agree to follow this project's Code of Conduct
adulau commented 1 year ago

phishtank introduces some limitation when downloading the feed multiple times:

You have exceeded the request rate limit for this method. Please see the response headers for usage stats. For more information about rate limiting on Phishtank, please see our developer site: http://www.phishtank.com/developer_info.php