doctor: add a "Password" row next to the 2FA row
Your AI's guard dog to stop it from going rogue.
Brought to you by:
doberman
Originally created by: fu351
doberman doctor reports whether TOTP is enrolled (_check_2fa, src/doberman/cli/doctor.py:213-220) but says nothing about the local password factor, even though doberman status already shows Password: enrolled/not set (src/doberman/cli/main.py:742) and doberman.auth.password.is_enrolled() exists (src/doberman/auth/password.py:82). A fresh install that skipped doberman password set passes doctor with no hint.
What to do
_check_password() mirroring _check_2fa line for line: import password from doberman.auth, OK "set" when password.is_enrolled(), else WARN "not set (optional) - run doberman password set".run_checks() (:252-262) right after the 2FA row, non-critical (False), same as 2FA.tests/unit/test_cli_doctor.py and tests/unit/test_cli_doctor_json.py: a Password row appears with the expected status (monkeypatch is_enrolled both ways).Read-only: is_enrolled() checks presence, never the secret.
Ticket changed by: fu351