jokob-sk / NetAlertX

πŸ–§πŸ” WIFI / LAN intruder detector. Scans for devices connected to your network and alerts you if new and unknown devices are found.
GNU General Public License v3.0
2.54k stars 148 forks source link

Add samba name to device discovery #693

Closed frazei closed 1 month ago

frazei commented 2 months ago

Is there an existing issue for this?

Am I willing to test this? πŸ§ͺ

Can I help implement this? πŸ‘©β€πŸ’»πŸ‘¨β€πŸ’»

Is your feature request related to a problem? Please describe

Many devices on my network are marked as '(name not found)', while in other network scans (such as Debookee and Fing), they are identified via NetBIOS/WINS/SMB.

Describe the solution you'd like

Use nbstat script for nmap or nmblookup to get device name

Describe alternatives you've considered

Don't know

Anything else?

https://nmap.org/nsedoc/scripts/nbstat.html https://unix.stackexchange.com/questions/170431/how-to-get-netbios-name-from-ip

jokob-sk commented 2 months ago

Hi there,

Thansk for teh sugegstion. Have you checked this guide?

https://github.com/jokob-sk/NetAlertX/blob/main/docs/REVERSE_DNS.md

jokob-sk commented 1 month ago

Hi @frazei ,

I looked into this briefly and according to this article the equivalent to nbstat is nslookup, which is already available as a plugin: https://www.geeksforgeeks.org/nbtstat-commnd-in-linux/

However, it makes probably sense to support NetBIOS lookup.

I create a NBTSCAN plugin that should be available in the next release. Please have a look at the netalertx-dev docker image, in about 15 minutes (or after the last action finishes) from now.

You need to load the plugin via the LOADED_PLUGINS setting.

πŸ‘‰If I don't get a confirmation that this is working I might pull out the feature to prevent bugs.

Make sure you refresh your browser cache - and click the πŸ”„ refresh button in the top right corner.

It would be great if you could test this (backup everything first or use a new container) on your end by switching to the above image and letting me know if the new feature is working.

⭐ This feature took 2h ⏳ to implement - consider becoming a sponsor or sharing the app on socials⭐

Thanks in advance, j

frazei commented 1 month ago

Hi @jokob-sk, I am testing the netalertx-dev image and the NBTSCAN plugin as you suggested. So far, it seems to be working correctly. I'll let it run for a while to see if it can detect new devices.

jokob-sk commented 1 month ago

Releasing -> closing