Ullaakut / cameradar

Cameradar hacks its way into RTSP videosurveillance cameras
MIT License
4.11k stars 516 forks source link

Cannot use file for target as namp will fail to resolve #310

Closed zorrobyte closed 3 months ago

zorrobyte commented 2 years ago

Given a list of IPs

12.125.12.5
12.125.12.4
12.125.12.2
12.125.12.87

and command: docker run -v "$(pwd):/data" --net=host -t ullaakut/cameradar -t /data/ips.txt -d -p 554

nmap reports

> [Nmap Warning] Failed to resolve "149.165.246.187
".> [Nmap Warning] Failed to resolve "149.165.246.187
etc...

and only the last IP in the list is actually scanned.

The file is a UTF-8 plaintext file: image

I'm running docker desktop on Windows with the provided example commands

vgpastor commented 2 years ago

You try to separate the ips with comma ,

Ullaakut commented 2 years ago

Hi @zorrobyte

The target list should indeed be newline-separated, so your file format seems good.

On your host machine, where is the file located? Is it in $(pwd)? Why iis the error talking about a target at IP 149.165.246.187 even though that one is not in your target file?

zorrobyte commented 2 years ago

Hi @zorrobyte

The target list should indeed be newline-separated, so your file format seems good.

On your host machine, where is the file located? Is it in $(pwd)? Why iis the error talking about a target at IP 149.165.246.187 even though that one is not in your target file?

I was just using pwd to mount the volume containing my file into the container (current dir), it was on my C: root at the time.

149.165.246.187 was just a random IP I changed from my own, so I don't doxx myself.

I'll try comma separating and trying again, will report back in a few days, or sooner

zorrobyte commented 2 years ago

Replicated @Ullaakut : image

Adding an additional space doesn't work, nor does adding a comma @vgpastor

This is a plaintext file formatted in UTF-8 I'm running Windows 11 with Docker Desktop in WSL2 mode, I have also tried Hyper-V mode with no change.

Can you attempt repo and share your OS and setup? I can try to replicate using the same.

Ullaakut commented 2 years ago

I've never attempted doing it in Windows, natively or through WSL, so that might be the source of the issue, but I don't see why it would be. I will check that the loader feature didn't get broken but last time I checked it worked fine on Linux and MacOS 🤔

Thanks for the detailed report 🙏

Ullaakut commented 3 months ago

Duplicate of #315