Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nagios/Centreon Integration #851

Open
sistemmsn opened this issue Dec 22, 2022 · 0 comments
Open

Nagios/Centreon Integration #851

sistemmsn opened this issue Dec 22, 2022 · 0 comments

Comments

@sistemmsn
Copy link

sistemmsn commented Dec 22, 2022

Expected behavior

I am trying to do this procedure use my nagios to be able to monitor vulnerability reports

https://docs.greenbone.net/GSM-Manual/gos-20.08/en/connecting-other-systems.html#nagios

Current behavior

image

10.0.5.2 is my openvas and when I try to connect it gives those errors, I'm using python 3.8, built since 3.6 gives crypt errors

#gvm-script ssh --hostname 10.0.5.2 --ssh-username nagios --ssh-password N4g10$ --gmp-username=admin --gmp-password=admin --protocol OSP check-gmp.gmp.py --ping --log DEBUG

Logs:

INFO:paramiko.transport:Connected (version 2.0, client OpenSSH_8.0)
INFO:paramiko.transport:Authentication (password) successful!
INFO:paramiko.transport:Connected (version 2.0, client OpenSSH_8.0)
INFO:paramiko.transport:Authentication (password) successful!
DEBUG:gvmtools.parser:Loaded config ~/.config/gvm-tools.conf
DEBUG:root:Parsed arguments Namespace(config='~/.config/gvm-tools.conf', connection_type='ssh', gmp_password='admin', gmp_username='admin', hostname='10.0.5.2', loglevel=None, port=22, protocol='GMP', scriptargs=['check-gmp.gmp.py'], scriptname='OSP', ssh_password='N4g10$', ssh_username='nagios', timeout=60)
DEBUG:paramiko.transport:starting thread (client mode): 0xa499d760
DEBUG:paramiko.transport:Local version/idstring: SSH-2.0-paramiko_2.12.0
DEBUG:paramiko.transport:Remote version/idstring: SSH-2.0-OpenSSH_8.0
INFO:paramiko.transport:Connected (version 2.0, client OpenSSH_8.0)
DEBUG:paramiko.transport:=== Key exchange possibilities ===
DEBUG:paramiko.transport:kex algos: curve25519-sha256, curve25519-sha256@libssh.org, ecdh-sha2-nistp256, ecdh-sha2-nistp384, ecdh-sha2-nistp521, diffie-hellman-group-exchange-sha256, diffie-hellman-group14-sha256, diffie-hellman-group16-sha512, diffie-hellman-group18-sha512, diffie-hellman-group-exchange-sha1, diffie-hellman-group14-sha1
DEBUG:paramiko.transport:server key: rsa-sha2-512, rsa-sha2-256, ssh-rsa, ecdsa-sha2-nistp256, ssh-ed25519
DEBUG:paramiko.transport:client encrypt: aes256-gcm@openssh.com, chacha20-poly1305@openssh.com, aes256-ctr, aes256-cbc, aes128-gcm@openssh.com, aes128-ctr, aes128-cbc
DEBUG:paramiko.transport:server encrypt: aes256-gcm@openssh.com, chacha20-poly1305@openssh.com, aes256-ctr, aes256-cbc, aes128-gcm@openssh.com, aes128-ctr, aes128-cbc
DEBUG:paramiko.transport:client mac: hmac-sha2-256-etm@openssh.com, hmac-sha1-etm@openssh.com, umac-128-etm@openssh.com, hmac-sha2-512-etm@openssh.com, hmac-sha2-256, hmac-sha1, umac-128@openssh.com, hmac-sha2-512
DEBUG:paramiko.transport:server mac: hmac-sha2-256-etm@openssh.com, hmac-sha1-etm@openssh.com, umac-128-etm@openssh.com, hmac-sha2-512-etm@openssh.com, hmac-sha2-256, hmac-sha1, umac-128@openssh.com, hmac-sha2-512
DEBUG:paramiko.transport:client compress: none, zlib@openssh.com
DEBUG:paramiko.transport:server compress: none, zlib@openssh.com
DEBUG:paramiko.transport:client lang: <none>
DEBUG:paramiko.transport:server lang: <none>
DEBUG:paramiko.transport:kex follows: False
DEBUG:paramiko.transport:=== Key exchange agreements ===
DEBUG:paramiko.transport:Kex: curve25519-sha256@libssh.org
DEBUG:paramiko.transport:HostKey: ssh-ed25519
DEBUG:paramiko.transport:Cipher: aes128-ctr
DEBUG:paramiko.transport:MAC: hmac-sha2-256
DEBUG:paramiko.transport:Compression: none
DEBUG:paramiko.transport:=== End of kex handshake ===
DEBUG:paramiko.transport:kex engine KexCurve25519 specified hash_algo <built-in function openssl_sha256>
DEBUG:paramiko.transport:Switch to new keys ...
DEBUG:paramiko.transport:Got EXT_INFO: {'server-sig-algs': b'ssh-ed25519,ssh-rsa,rsa-sha2-256,rsa-sha2-512,ssh-dss,ecdsa-sha2-nistp256,ecdsa-sha2-nistp384,ecdsa-sha2-nistp521'}
DEBUG:paramiko.transport:userauth is OK
INFO:paramiko.transport:Authentication (password) successful!
DEBUG:paramiko.transport:[chan 0] Max packet in: 32768 bytes
DEBUG:paramiko.transport:Received global request "hostkeys-00@openssh.com"
DEBUG:paramiko.transport:Rejecting "hostkeys-00@openssh.com" global request from server.
DEBUG:paramiko.transport:[chan 0] Max packet out: 32768 bytes
DEBUG:paramiko.transport:Secsh channel 0 opened.
DEBUG:paramiko.transport:[chan 0] Sesch channel 0 request ok
DEBUG:paramiko.transport:[chan 0] EOF received (0)
DEBUG:paramiko.transport:[chan 0] EOF sent (0)
DEBUG:paramiko.transport:Dropping user packet because connection is dead.

now carry out the same process but now inside the openvas server, I already have 2 test reports, when I want to run the script, it runs correctly but it does not show the statuses, it just says Ok but actually if there is critical, I present evidence

Steps to reproduce

1.python3.8 -m pip install --user gvm-tools
2.wget https://raw.githubusercontent.com/greenbone/gvm-tools/main/scripts/check-gmp.gmp.py
3.image
4.image

GVM versions

gsa: (Greenbone Security Assistant 22.04.0)

gvm: (Greenbone Vulnerability Manager 22.4.0~dev1)

openvas-scanner: (OpenVAS 22.4.0)

gvm-libs: 22.4.0

gvm-tools: (gvm-cli 22.9.0 (API version 22.9.1))

Environment

Operating system: Alma Linux 8.6

Installation method / source: (packages, source installation)

Logfiles

[gvmd.log](https://github.com/greenbone/gvm-tools/files/10290248/gvmd.log)
[openvas.log](https://github.com/greenbone/gvm-tools/files/10290249/openvas.log)
[ospd-scanner.log](https://github.com/greenbone/gvm-tools/files/10290250/ospd-scanner.log)
[gsad.log](https://github.com/greenbone/gvm-tools/files/10290251/gsad.log)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant