Vulnerabilities in pkg:pypi/azure-storage-blob
PACKAGECVE-2022-30187 is a MODERATE (CVSS 4.7) cbc padding oracle vulnerability (CWE-668: Exposure of Resource to Wrong Sphere) affecting Microsoft libraries in the NuGet ecosystem. The issue involves cbc padding oracle in azure blob storage encryption library. Remediation is available by upgrading affected packages to version 12.11.0, 12.13.0, 12.18.0, 12.4.0.
pkg:pypi/azure-storage-blob
Vulnerability advisories affecting package pkg:pypi/azure-storage-blob. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-64x4-9hc6-r2h6 | CVE-2022-30187 | MODERATE | Microsoft: CBC Padding Oracle in Azure Blob Storage Encryption Library |
CVE-2022-30187 at a Glance
Security Impact
CVSS: 4.7
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N).
How to Fix CVE-2022-30187
To remediate this vulnerability, upgrade all affected Microsoft dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade Azure.Storage.Queues to 12.11.0
Upgrade Azure.Storage.Blobs to 12.13.0
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-storage-blob</artifactId>
<version>12.18.0</version>
</dependency>
pip install azure-storage-queue>=12.4.0
pip install azure-storage-blob>=12.13.0
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for Azure.Storage.Queues
How to Check if You Are Affected
To determine whether your application is affected by CVE-2022-30187, inspect your project dependencies for Microsoft:
inspect dependencies for Azure.Storage.Queues
Analyze the terminal output to locate any version of Microsoft in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 12.11.0), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-668: Exposure of Resource to Wrong Sphere, where the product exposes a resource to the wrong control sphere, providing unintended actors with inappropriate access to the resource. In Microsoft, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2022-30187 Affected Microsoft Versions
5 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
Azure.Storage.Queues
|
NuGet |
< 12.11.0
|
12.11.0
|
|
Azure.Storage.Blobs
|
NuGet |
< 12.13.0
|
12.13.0
|
|
com.azure:azure-storage-blob
|
Maven |
< 12.18.0
|
12.18.0
|
|
azure-storage-queue
|
PyPI |
< 12.4.0
|
12.4.0
|
|
azure-storage-blob
|
PyPI |
< 12.13.0
|
12.13.0
|
References
Frequently Asked Questions
What is CVE-2022-30187?
Which Microsoft versions are affected?
What version fixes CVE-2022-30187?
Is Azure.Storage.Queues affected?
Is Azure.Storage.Blobs affected?
What is the CVSS score of CVE-2022-30187?
What CWE is associated with CVE-2022-30187?
How can I check NuGet dependencies for CVE-2022-30187?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-64x4-9hc6-r2h6",
"modified" : "2024-05-23T17:12:42Z",
"published" : "2022-07-13T00:00:39Z",
"aliases" : [ "CVE-2022-30187" ],
"summary" : "Microsoft: CBC Padding Oracle in Azure Blob Storage Encryption Library",
"details" : "### Summary\n\nThe Azure Storage Encryption library in Java and other languages is vulnerable to a CBC Padding Oracle attack, similar to CVE-2020-8911. The library is not vulnerable to the equivalent of CVE-2020-8912, but only because it currently only supports AES-CBC as encryption mode. \n\n### Severity\n\nModerate - The vulnerability poses insider risks/privilege escalation risks, circumventing controls for stored data.\n\n### Further Analysis\nThe Java Azure Blob Storage Encryption SDK is impacted by an issue that can result in loss of confidentiality and message forgery. The attack requires write access to the container in question, and that the attacker has access to an endpoint that reveals decryption failures (without revealing the plaintext) and that when encrypting the CBC option was chosen as content cipher.\n\nThis advisory describes the plaintext revealing vulnerabilities in the Java Azure Blob Storage Encryption SDK, with a similar issue in the other blob storage SDKs being present as well.\n\nIn the current version of the Azure Blob Storage crypto SDK, the only algorithm option that allows users to encrypt files is to AES-CBC, without computing a MAC on the data.\n\nThis exposes a padding oracle vulnerability: If the attacker has write access to the blob container bucket and can observe whether or not an endpoint with access to the key can decrypt a file (without observing the file contents that the endpoint learns in the process), they can reconstruct the plaintext with (on average) 128*length(plaintext) queries to the endpoint, by exploiting CBC's ability to manipulate the bytes of the next block and PKCS5 padding errors.\n\n### Timeline\n**Date reported**: March 29 2022\n**Date preview**: June 16 2022\n**Date GA**: July 11 2022\n**Date disclosed**: July 17 2022",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:L/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "NuGet",
"name" : "Azure.Storage.Queues"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "12.11.0"
} ]
} ]
}, {
"package" : {
"ecosystem" : "NuGet",
"name" : "Azure.Storage.Blobs"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "12.13.0"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "com.azure:azure-storage-blob"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "12.18.0"
} ]
} ]
}, {
"package" : {
"ecosystem" : "PyPI",
"name" : "azure-storage-queue"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "12.4.0"
} ]
} ]
}, {
"package" : {
"ecosystem" : "PyPI",
"name" : "azure-storage-blob"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "12.13.0"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/google/security-research/security/advisories/GHSA-6m8q-r22q-vfxh"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2022-30187"
}, {
"type" : "WEB",
"url" : "https://msrc.microsoft.com/update-guide/vulnerability/CVE-2022-30187"
}, {
"type" : "WEB",
"url" : "https://portal.msrc.microsoft.com/en-US/security-guidance/advisory/CVE-2022-30187"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-668" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2022-07-21T22:35:57Z",
"nvd_published_at" : "2022-07-12T23:15:00Z"
}
}