Cyber Security News

Hackers Exploit Stolen Certificates and Private Keys to Breach Organizations

Recent research has unveiled a concerning vulnerability within the realm of containerized applications, where threat actors are leveraging stolen certificates and private keys to infiltrate organizations.

This tactic not only allows hackers to bypass security measures but also potentially permits them to remain undetected for extended periods, posing significant risks to corporate security.

The Stealth of Compromised Certificates

Certificates and private keys, unlike typical secrets such as API tokens or passwords, carry unique attributes that make them exceptionally perilous when compromised.

An SSL/TLS certificate or SSH key serves not merely as a secret; it acts as an identity, enabling systems or users to authenticate themselves as legitimate entities.

How threat actors could gain access to the registry

Once in the hands of attackers, these keys can enable them to impersonate servers or users, leading to scenarios where organizations unknowingly connect to malicious resources, mistaking them for trustworthy entities due to the legitimate credentials presented.

The implications of this are profound. While API tokens and passwords can be rotated with relative ease, certificates and keys are embedded within a more formal trust chain, making their revocation and reissuance a complex process.

This characteristic extends the window of exposure, allowing attackers to operate stealthily, blending malicious traffic with legitimate communications.

Real-World Examples and Consequences

In one studied case, a container image was found to be harboring both OpenVPN certificates (along with private keys) and SSH private keys.

Content of the private key present inside the container image

OpenVPN, a widely used technology for establishing secure VPN tunnels, relies heavily on these certificates and keys to ensure encrypted connections.

When these secrets are compromised, attackers can set up rogue VPN servers or gain unauthorized access to an organization’s private network, sniffing traffic, exfiltrating data, or launching supply chain attacks.

Similarly, SSH, the protocol for secure remote server administration, becomes a gateway for attackers if its keys are compromised.

An attacker gaining access to an SSH private key can log into servers or systems without the need for password authentication, often leading to further unauthorized access, data breaches, or server compromise across multiple environments.

The core issue stems from the exposure of container registries, which act as warehouses storing sensitive images.

These registries, if not properly secured or if credentials are leaked, provide a treasure trove of information for attackers.

The research identified over 20,500 images across 197 registries containing more than 9.36 TB of data, with some images inadvertently including sensitive files like private keys and certificates.

Organizations must adopt stringent practices to mitigate these risks:

  • Separate Build and Production Environments: Avoid storing secrets in development or testing environments. Use environment variables or secure vaults for runtime injection of credentials.
  • Implement Secret Scanning: Utilize tools to scan container images for sensitive files before they reach the registry or during the CI/CD pipeline.
  • Robust Code Reviews: Regularly review Dockerfiles and configuration files to ensure no sensitive data is inadvertently included.

The stealthy nature of compromised certificates and keys underscores the need for heightened vigilance in managing containerized environments.

The long-term research into exposed private registries has underscored the plausibility and severity of these breaches, pushing for an overhaul in how organizations secure their digital identities.

Find this News Interesting! Follow us on Google News, LinkedIn, & X to Get Instant Updates!

Aman Mishra

Aman Mishra is a Security and privacy Reporter covering various data breach, cyber crime, malware, & vulnerability.

Recent Posts

Hackers Use ConnectWise SkyKick Credentials to Access Microsoft 365, Halting Cloud Backups

Attackers abused compromised ConnectWise Cloud Backup credentials to access Microsoft 365 customer environments, prompting ConnectWise…

1 day ago

Anthropic’s Claude AI Uncovers Origins of NSA-Provided Cryptographic Keys After 25 Years

Anthropic says an internal Claude research model reconstructed how the National Security Agency generated seeds…

1 day ago

Critical WordPress Flaws Allow Attackers to Execute Remote Code Without Authentication

Two WordPress Core vulnerabilities can be chained to execute remote code without authentication, according to…

1 day ago

OpenBSD Kernel Flaw Dating Back 37 Years Enables Local Privilege Escalation to Root

A newly disclosed OpenBSD kernel exploitation chain combines a shared memory accounting flaw with a…

1 day ago

GhostAction Hackers Hide Credential-Stealing Malware in Fake Font Files Across 94 GitHub Repositories

GhostAction attackers have expanded their GitHub credential theft campaign with a second stage that disguises…

1 day ago

SideCopy Hackers Target Indian Organizations With ReverseRAT Malware to Steal Data

Indian authorities have warned that SideCopy hackers are targeting Indian organizations, including academic institutions, with…

2 days ago