Commit Graph
3 Commits
Author SHA1 Message Date
Christian Manivong 672bc04261 fix: what bandit and the remaining lint rules found
- Netgear Plus: a failed logout on close() now logs at debug level (B110),
  so a swallowed failure leaves a trace; the module gets its logger.
- nosec for the firmware CDN probe (B310): the URL is built on the fixed
  https base _FW_CDN_BASE, model and version only fill its path, so no
  file:// or custom scheme can reach urlopen.
- nosec for the empty password in get_users (B105): it is NAPALM's field,
  the CLI never shows a password; a false positive.
- The v7 LLDP table in a docstring loses one leading space per line to fit
  line length 100.
- tests: a second TestGetLldpNeighbors class shadowed the first, whose two
  tests never ran; the v7 one is now TestGetLldpNeighborsV7 and both run
  (and pass). raise ... from exc in the netmiko stand-in.
2026-10-23 08:34:17 +02:00
Christian Manivong fa10d6617b style: ruff format and the lint rules of the driver standard
Mechanical: ruff format, and ruff check --fix with the rule set every NAPALM
driver uses (E, F, I, UP, B at line length 100, Python 3.10). What ruff
cannot fix comes in the next commit.
2026-10-23 08:32:43 +02:00
Christian Manivong 2de5844f92 fix(ssh): verify the host key netOrk expects, report the one seen (NetOrk/netork#1167)
CI / test (3.10) (push) Successful in 33s
CI / test (3.11) (push) Successful in 32s
CI / test (3.12) (push) Successful in 31s
CI / test (3.10) (pull_request) Successful in 27s
CI / test (3.11) (pull_request) Successful in 24s
CI / test (3.12) (pull_request) Successful in 26s
The driver accepted any SSH host key. It now verifies through
napalm-device-types' HostKeyCheck (>= 4.19.0): with a known key in
optional_args["ssh_host_keys"] any other key is refused before login, and
every key seen is reported to optional_args["ssh_host_key_observer"].
Without either argument it connects as before (first use).
2026-10-18 21:23:41 +02:00