# CVE-2024-41178: Apache Arrow Rust Object Store: AWS WebIdentityToken exposure in log files

> Attackers with log access can steal AWS WebIdentityTokens to impersonate identities and access cloud resources.

- **Severity:** High 7.5 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 23 Jul 2024
- **Updated:** 13 Aug 2024
- **Also known as:** GHSA-c2hf-vcmr-qjrf, RUSTSEC-2024-0358

## What is CVE-2024-41178?

CVE-2024-41178 is a high-severity vulnerability in Apache Arrow Rust Object Store, published on 23 Jul 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

Exposure of temporary credentials in logs in Apache Arrow Rust Object Store (`object_store` crate), version 0.10.1 and earlier on all platforms using AWS WebIdentityTokens. 

On certain error conditions, the logs may contain the OIDC token passed to  AssumeRoleWithWebIdentity https://docs.aws.amazon.com/STS/latest/APIReference/API_AssumeRoleWithWebIdentity.html . This allows someone with access to the logs to impersonate that identity, including performing their own calls to AssumeRoleWithWebIdentity, until the OIDC token expires. Typically OIDC tokens are valid for up to an hour, although this will vary depending on the issuer.

Users are recommended to use a different AWS authentication mechanism, disable logging or upgrade to version 0.10.2, which fixes this issue.

Details:

When using AWS WebIdentityTokens with the object_store crate, in the event of a failure and automatic retry, the underlying reqwest error, including the full URL with the credentials, potentially in the parameters, is written to the logs. 

Thanks to Paul Hatcherian for reporting this vulnerability

Weakness: CWE-532 (Insertion of Sensitive Information into Log File)

## Which versions are affected by CVE-2024-41178?

3 open source packages ship an affected version, including object_store. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `object_store` | crates.io | From 0.5.0 | 0.10.2 |
| `object_store` | crates.io | From 0.5.0 | 0.10.2 |
| `object_store` | crates.io | From 0.5.0 | 0.10.2 |

Products: Apache Arrow.

## How do I fix CVE-2024-41178?

Upgrade object_store to 0.10.2 or later.

## Is CVE-2024-41178 being exploited?

There is no known exploitation of CVE-2024-41178 in the wild and no public exploit code.

## Other vulnerabilities in Apache Arrow Rust Object Store

- [CVE-2024-52338](https://insights.sbomify.com/CVE-2024-52338/): Apache Arrow R package: Arbitrary code execution when loading a malicious data file (critical 9.8)
- [CVE-2019-12408](https://insights.sbomify.com/CVE-2019-12408/): Missing Initialization of Resource in Apache Arrow (high 7.5)
- [CVE-2019-12410](https://insights.sbomify.com/CVE-2019-12410/): Missing Initialization of Resource in Apache Arrow (high 7.5)
- [CVE-2026-25087](https://insights.sbomify.com/CVE-2026-25087/): Apache Arrow: Potential use-after-free when reading IPC file with pre-buffering (high 7.0)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2024-41178 and fix it if it is affected.

What it is: CVE-2024-41178 is a high-severity vulnerability in Apache Arrow Rust Object Store, published on 23 Jul 2024. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2024-41178 in the wild and no public exploit code.

Affected packages and fixed versions:
- object_store (crates.io): affected from 0.5.0; fixed in 0.10.2
- object_store (crates.io): affected from 0.5.0; fixed in 0.10.2
- object_store (crates.io): affected from 0.5.0; fixed in 0.10.2

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2024-41178/ (Markdown: https://insights.sbomify.com/CVE-2024-41178/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2024-41178
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2024-41178
- OSV: https://osv.dev/vulnerability/CVE-2024-41178

---
From sbomify Insights: https://insights.sbomify.com/CVE-2024-41178/
Summaries are generated and may contain mistakes; the official description above is the record.
