Join our Newsletter — 33% off our NHI Course
Home› Glossary› Authentication, Authorisation & Trust› SSH Keys and Certificates
Authentication, Authorisation & Trust

SSH Keys and Certificates

← Back to Glossary
By NHI Mgmt Group Updated November 26, 2026 Domain: Authentication, Authorisation & Trust

SSH Keys and Certificates are credentials for authenticating to SSH servers: key pairs, and public keys signed by a certificate authority with an identity and validity period. Unmanaged keys in authorised key files rarely expire and enable lateral movement. Certificates allow short lifetimes and central issuance, so inventory keys, remove stale ones and rotate.

What SSH keys and SSH certificates do

SSH keys and SSH certificates both authenticate a client or host to an SSH server, but they do it differently. A raw key pair relies on a long-lived public key stored on the server, while a certificate adds a signed identity, validity window, and policy from a certificate authority. That makes certificates easier to govern at scale and easier to expire cleanly.

For operators, the practical distinction is control. A bare key can sit in authorised_keys for years, especially in shared admin or automation paths, whereas a certificate can be issued for a limited purpose and time window. The term therefore covers both the cryptographic credential and the lifecycle controls around it.

Why unmanaged SSH keys become an access problem

SSH keys are powerful because they often bypass interactive login friction, but that also makes them attractive for persistence. Once a key is copied into authorised_keys, it may continue working long after the original user, host, or automation job should have lost access. Stale keys can create hidden trust paths that are hard to see from directory or IAM reviews alone.

That risk grows when keys are reused across many systems, embedded in scripts, or left on servers after staff leave. Certificates reduce that exposure by making trust explicit and time-bound, but only if the issuing process, principals, and revocation controls are actually managed. Good hygiene means treating SSH access as governed identity material, not just a file on disk.

NHIMG’s SSH Key and SSH Certificate Management Guide covers the practical work of finding sprawl, governing authorised_keys, and rotating orphaned access paths.

How SSH certificates change the trust model

SSH certificates shift trust from “this public key is on the server” to “this key was signed by a trusted CA for a specific identity and period.” That allows central issuance, shorter lifetimes, and cleaner revocation patterns than ad hoc key distribution. It also gives organisations a better way to separate user identity, host identity, and automation identity.

Certificates are especially useful where access needs to be temporary, delegated, or frequently changed. They fit environments that need traceability over who can reach which host, while still preserving the operational flexibility that makes SSH attractive. The trade-off is that CA custody, principals, and revocation become critical control points.

For broader identity architecture, NHIMG’s Guide to SPIFFE and SPIRE shows the same “short-lived, centrally issued identity” idea in workload identity systems.

Common failure modes and what they look like in practice

The most common failure modes are key sprawl, overbroad trust, missing expiry, and incomplete offboarding. A key can be technically strong and still be operationally unsafe if nobody can answer where it lives, who owns it, whether it is still needed, or what systems accept it. Certificates reduce some of that burden, but only when certificate authorities, host trust settings, and revocation lists are consistently enforced.

Another failure mode is treating SSH access as a one-time setup task instead of a lifecycle. That usually leads to dormant keys, automation credentials that outlive the job they were created for, and hidden lateral-movement paths if one key is compromised. Inventory and periodic review are therefore part of the security model, not an optional admin chore.

When SSH trust has to be governed across Linux fleets, NHIMG’s Unix and Linux Privileged Access Guide provides the surrounding access-control context.

Detection and response after key exposure

If an SSH private key is exposed, treat it as an access compromise, not just a configuration issue. The response usually has to include locating where the key was authorised, identifying whether it was copied into other systems or images, and removing trust from every place it can still be accepted. If certificates were in use, revocation or CA-side invalidation becomes part of the recovery path.

Review logs for successful SSH use, unusual source systems, and any evidence that the key was used to pivot into other hosts or repositories. After suspected exploitation, rotate any related secrets or tokens that may have been reachable from the same session or automation path, because the SSH credential may only be the first step in a broader compromise.

NHIMG’s SSH Key Compromise Response Playbook details the response sequence for leaked private keys and certificate revocation.

Risk and Threat Considerations

SSH keys are high-value credentials because they can enable direct host access, privilege escalation, and lateral movement without interactive password challenges. The danger is not the cryptography itself, but the persistence of trust when keys are not inventoried, expired, or removed after their intended use.

Failure mechanism: Attackers or insiders abuse long-lived authorised keys, copied private keys, or overtrusted certificates to regain access after the original account path should have been closed.

Impact: A single exposed SSH credential can become durable remote access across multiple systems, often with enough reach to stage deeper compromise, harvest secrets, or move laterally.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

MITRE ATT&CK addresses the attack and risk surface, while NIST SP 800-57, NIST SP 800-53 Rev 5 and CIS Controls v8 set the governance and control requirements practitioners need to meet.

FrameworkControl / ReferenceRelevance
NIST SP 800-57Key ManagementSSH keys and certificates are key lifecycle material that needs rotation, revocation, and custody control.
Recommendation — Define cryptoperiods, rotate exposed keys, and govern certificate issuance and revocation as part of key lifecycle management.
NIST SP 800-53 Rev 5IA-5 — Authenticator ManagementSSH keys and certificates are authenticators whose issuance, storage, rotation, and revocation must be controlled.
IA-2 — Identification and Authentication (Organizational Users)SSH access for admins and operators is a user authentication path that depends on strong credential governance.
Recommendation — Manage SSH keys and certificates as authenticators, including provisioning, rotation, revocation, and removal of stale material. Require strong user authentication for SSH access and remove standing key-based access when it is no longer needed.
CIS Controls v8CIS-5 — Account ManagementSSH authorised_keys and certificate access are account-access mechanisms that need inventory and offboarding.
Recommendation — Inventory SSH access paths, remove dormant keys, and tie access removal to user and system offboarding.
MITRE ATT&CKT1098.004 — SSH Authorized KeysSSH authorised keys are a documented persistence technique used to maintain remote access after compromise.
Recommendation — Hunt for added or modified SSH authorised keys and remove any attacker-controlled persistence.

Practitioner Guidance

Why practitioners should care: The governance question is not whether SSH works, but whether every trusted key or certificate has an owner, purpose, and expiry that can be enforced. Short-lived certificates help, but only if the organisation can actually issue, track, and revoke them consistently.

Practitioner takeaway: Treat SSH access as a managed identity lifecycle, not a static file distribution problem, and prefer certificate-based access where you need scalable expiry and revocation.

Free weekly newsletter

Subscribe to the NHI & AI Identity Journal

The latest on NHI and Agentic AI security – articles, research, breaches, news and events every week.

Bonus 33% off our NHI Course when you subscribe.

NHIMG Editorial Note
Reviewed and updated by the NHIMG editorial team on November 26, 2026.
NHI Mgmt Group — the #1 independent authority on Non-Human Identity, IAM, and Agentic AI security. nhimg.org