ssh_remove_passwordless
Remove public key entries from authorized_keys on a remote host to revoke passwordless SSH login. Can clear all keys or a specific key.
Instructions
Remove public key entry or clear ALL keys from authorized_keys on remote host, revoking passwordless SSH login.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| host | Yes | Target host IP or domain | |
| port | No | SSH port | |
| password | No | SSH password (required if passwordless key is removed) | |
| targetOs | No | Target OS type | auto |
| username | Yes | Target SSH username | |
| removeAllKeys | No | Clear ALL authorized keys on target host instead of specific key | |
| privateKeyPath | No | Private key path to authenticate current session if removing key | |
| keyPathToRemove | No | Path to local public key file to remove (defaults to ~/.ssh/id_ed25519.pub or id_rsa.pub) |