vulnerable-api
vulnerable-api copied to clipboard
How to limit wide open 0.0.0.0 to 127.0.0.1 ?
First of all, thanks for such cool project. Quick question, when I run this, it opens port the connection to my local computer pretty much open wide (0.0.0.0). How do I limit this to only localhost (127.0.0.1) as this software is meant to be vulnerable?
$ python vAPI.py
* Serving Flask app 'vAPI'
* Debug mode: on
$ ss -antp | grep python
LISTEN 0 128 0.0.0.0:8081 0.0.0.0:* users:(("python",pid=18589,fd=6),("python",pid=18589,fd=4),("python",pid=18587,fd=6),("python",pid=18587,fd=4))
$
In vapy.py there is a line at the end (395) containing app.run(). If you add host=“localhost” as argument it will probably do what you want.