项目作者: ToroNZ

项目描述 :
Netbox-scanner in a container bro
高级语言: Dockerfile
项目地址: git://github.com/ToroNZ/netbox-scanner-container.git
创建时间: 2020-03-03T18:12:18Z
项目社区:https://github.com/ToroNZ/netbox-scanner-container

开源协议:

下载


a dockerfile that installs netbox-scanner and runs with it… this can be deployed alongside netbox or into any container runtime you need.

Check their wiki

Build it

  1. git clone https://github.com/ToroNZ/netbox-scanner-container
  2. cd netbox-scanner-container
  3. docker build -t toronz/nebox-scanner-docker:latest .

Run it

If your running it for the first time, create a sample config file:

  1. tee `pwd`/.netbox-scanner.conf <<EOF
  2. [GENERAL]
  3. tag = auto
  4. vrf =
  5. unknown = unknown host
  6. log = .
  7. nmap_args = -T4 -F -R --host-timeout 30s
  8. [NETBOX]
  9. address = http://netbox:8001
  10. token = YOUR_TOKEN_HERE
  11. tls_verify = False
  12. [TACACS]
  13. user = netbox
  14. password =
  15. command = show run | inc hostname
  16. regex = hostname ([A-Z|a-z|0-9|\-|_]+)
  17. regroup = 1
  18. [SCAN]
  19. networks = 192.168.21.0/26,10.0.1.0/24
  20. EOF

After the config is set, you can mount it as follows:

docker run --rm -ti --user 1000320000 --cap-drop=all -v `pwd`/.netbox-scanner.conf:/home/netbox/.netbox-scanner.conf toronz/netbox-scanner-docker:latest

OS Recognition

Won’t work due to the lack of permissions of this image (rootless).

If you want to use the nmap flag “-O” (OS recon), you need to build this container using a privileged user (root/sudo) so nmap can create raw sockets.