# Ensure your SSH key can reach the targetssh admin@192.168.1.10 "echo connected"
# Use -p to prompt securely for a passwordkensa check -h 192.168.1.10 -u admin -p --sudo
The -p flag without a value prompts interactively with hidden input. You can also pass a password inline with -p mypassword, but interactive prompting is more secure.
Most compliance checks require root privileges. Configure passwordless sudo for the SSH user:
# On the target host, grant passwordless sudo:echo "admin ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/kensa
This probes the target and reports its platform (e.g., RHEL 9.3) and detected capabilities (authselect, crypto policies, sshd_config.d support, etc.). Use this to verify connectivity before running checks.
2
Run compliance checks
kensa check -h 192.168.1.10 -u admin --sudo
Each rule produces a result:
Status
Meaning
PASS
Host meets the compliance requirement
FAIL
Host does not meet the requirement — remediation available