infinition / Bjorn

Bjorn is a powerful network scanning and offensive security tool for the Raspberry Pi with a 2.13-inch e-Paper HAT. It discovers network targets, identifies open ports, exposed services, and potential vulnerabilities. Bjorn can perform brute force attacks, file stealing, host zombification, and supports custom attack scripts.
MIT License
1.89k stars 62 forks source link

Port Issues when restarting Bjorn service #16

Open IncredibleZuess opened 4 days ago

IncredibleZuess commented 4 days ago

Description

There is an issue with threading where the web server does not exit and unbind the port fully sometimes before the new web server thread is initialized which results in the server ports hopping from 8000 to 8001

Steps to Reproduce:

Let Bjorn start normally then after a few seconds run:

sudo systemctl restart bjorn.service

Setup:

Hardware:

Actual Behaviour:

First Stop

image image

Second Stop:

image image

Interesting Note

While writing the issue I noticed that this only happens when the web page is rendered in a browser so it may be that the console being rendered in the web app is adding a few seconds before stopping the server completely

infinition commented 2 days ago

Yes, unfortunately, i did not manage to free up the 8000 port when i restart the Bjorn service. This is why i created a .sh file to kill the pid when the service starts.

My only workaround for now was incremental solution.But i hope this problem will be solved in next releases