Parse & filter the latest CVEs from https://cve.mitre.org
http://localhost:4000/cve?target=KEYWORD
The year parameter is optional.
http://localhost:4000/cve?target=KEYWORD&year=YEAR
http://localhost:4000/cve?target=ruby%20on%20rails
http://localhost:4000/cve?target=ruby%20on%20rails&year=2020
If you want to parse the latest year, use the "latest" keyword.
http://localhost:4000/cve?target=ruby%20on%20rails&year=latest
- Download the project
bundle install
ruby rest.rb
You can switch between prod & dev at config/environment.rb
You need to create one yourself, an example can be found here.
The url will return a status code of 200 which means the api is healthy.
If 200 is not shown then you should assume there is something wrong.
http://localhost:4000/status
You can access the api via http://localhost:4000/
You should be able to view the index page from the url.
docker build . -t cve-api
docker run -p 4000:4000 -d cve-api
docker ps
docker stop ID
docker rmi cve-api