Defender for cloud's Agentless secret scanning for virtual machines is now generally available!
Published Nov 29 2023 09:41 AM 4,575 Views
Microsoft

Cloud cybersecurity is of paramount importance in today's digital landscape, as organizations increasingly rely on cloud services to store and manage sensitive data, applications, and infrastructure. Attacks on cloud infrastructure pose severe risks to organizations such as data theft, ransomware attacks, crypto mining attacks, and service disruption.

During a cyber-attack, after gaining initial access to the target network, the attacker begins to move deeper into the network in search of sensitive data and other high-value assets. This stage, called lateral movement, is critical, as it enables threat actors to explore and expand their presence within a target network, increasing the potential for further compromise of critical systems.

One of the most common techniques used by hackers to move laterally in a network is credential theft. This technique involves the exploitation of exposed secrets such as passwords, keys, tokens, and connection strings to gain access to additional assets in the network. Secrets are often found on files, stored on the disks of virtual machines (VMs) or containers running on various cloud platforms.

 

The exposed secrets challenge:

Having exposed secrets can happen due to the following reasons:

  • Lack of awareness: Some organizations may not be aware of the risks and consequences of exposing secrets in their cloud environment. They may not have a clear policy or guidance on how to handle and protect secrets in their code and configuration files.
  • Lack of discovery tools: due to missing tools or processes to detect and remediate secrets leaks.
  • Complexity and speed: Modern software development is complex and fast-paced, relying on multiple cloud platforms, open-source software, and third-party code. Developers may use secrets to access and integrate various resources and services in their cloud environment. They may also store secrets in their source code repositories for convenience and reuse. It can lead to accidental exposure of secrets in public or private repositories, or during data transfer or processing.
  • Trade-off between security and usability: Some organizations may choose to keep secrets exposed in their cloud environment for usability reasons, to avoid the complexity and latency of encrypting and decrypting data at rest and in transit. This can compromise the security and privacy of their data and credentials.

 

Defender for cloud's Agentless secret scanning for virtual machines:

The agentless secret scanning is designed to assist in mitigating the risk of lateral movement. It broadens the coverage of cloud assets, enabling quick detection, prioritization, and remediation of exposed secrets.

Utilizing cloud APIs, it captures snapshots of your disks and conducts an out-of-band analysis, ensuring no impact on your virtual machines' performance. In addition, it identifies a variety of secrets across Azure, AWS, and GCP and provides practical suggestions for the following mitigations:

  1. Elimination of unnecessary secrets.
  2. Apply the Principle of Least Privilege.
  3. Strengthening the security of your secrets by employing secret management systems such as Azure Key Vault when possible.
  4. Usage of short-lived secrets, such as substituting Azure Storage connection strings with SAS tokens that possess shorter validity periods.

 

Onboarding:

Knowing that assets’ coverage plays crucial roles, we created a straightforward, easy onboarding experience – just one click, and all assets under the specified subscription is covered by our agentless scanning capability

 

talberdah_4-1701236576135.png

Agentless scanning configuration within the Defender for Servers settings

 

 

Detection and prioritization:

Microsoft’s secrets detection engine can identify a wide range of secret types, such as tokens, passwords, keys, or credentials, that are stored in different file types within the OS file system. After collecting the necessary file and secrets’ metadata from the disk, it sends them to the Defender for cloud portal.

 

Prioritizing secrets can be a daunting task. You may wonder which secrets are the riskiest and require immediate attention. To evaluate the severity and urgency of each secret we detected, we provide:

  1. Rich metadata for every secret we detect such as the file’s last access time, token expiration date, an indication if the target resource that the secret provides access to exists and more.
  2. We also combine the secrets’ metadata with the assets cloud context, helping you to start with assets that are exposed to the internet and contain secrets that may compromise other sensitive assets. We are happy to announce that the secrets scanning findings will be also incorporated into our new DCSPM risk-based approach to prioritize recommendation and enhance attack path analysis.
  3. We have developed multiple views to assist you in pinpointing the most commonly found secrets or assets containing secrets. This enables a prioritized approach towards the elimination of exposed secrets.

Security Recommendations:

talberdah_3-1701236533962.png

Enhanced recommendation experience aggregated by secret type

 

The security recommendations for secrets offer a consolidated view of the detected secrets, including details such as the file location of the secrets, the last access time, an indicator if the target resource that the secret provides access to exists, and more.

 

Attack Path:

talberdah_2-1701236318747.png

In this attack scenario, our scanner identified an AWS access key on the disk of an GCP VM instance. It was then able to pinpoint the AWS S3 bucket that the key could authenticate to. Leveraging the capabilities of Microsoft Defender CSPM, the attack path revealed that the initial GCP VM instance has a critical vulnerability and is exposed to the internet. This comprehensive context equips you with the necessary information for effective risk assessment and prioritization.

 

Cloud Security Explorer:

talberdah_5-1701236814514.png

Use the cloud security explorer to search for plaintext secrets 

 

Secret’s tab (inventory):

talberdah_0-1701270298469.png

Use the secret's tab to view all secrets detected for a specified virtual machine 

 

We are thrilled to announce that the Agentless secret scanning for virtual machines is now GA for Defender CSPM and Defender for Servers P2 plans. To start using this new feature, ensure that agentless scanning under the environment settings is enabled for the relevant subscriptions. For customers who have already enabled the agentless scanning, there’s no further action needed.

To learn more regarding the prerequisites, detection, capabilities and more, please refer the following documentation.

 

2 Comments
Version history
Last update:
‎Dec 18 2023 11:08 AM
Updated by: