Email-derived URL path injection in the Swoosh Microsoft Graph adapter
URL path injection in the Microsoft Graph adapter of Swoosh. Swoosh.Adapters.MsGraph builds its Microsoft Graph API request URL by interpolating the sender's email address into the URL path (/users/{from}/sendMail) without percent-encoding or validation. In applications that derive the from address from untrusted or user-influenced input (for example a relay, a contact form, or a "send as" feature), an attacker can place URL-special characters such as /, ?, or # in the local part of the address to escape the intended path segment and rewrite the path and query string of the request. Because the same authenticated POST is sent with the application's Microsoft Graph bearer token, the attacker can redirect it to other Graph endpoints within the token's scopes and control the request's query string. Applications that always use a fixed, trusted from address are not affected. This issue affects swoosh: from 1.12.0 before 1.26.3.
CVE-2026-54893
Primary source · Revision 1
Imported from structured advisory data. Source references identify upstream records or fields; verify affected versions and your deployed configuration.
Security context
Source reference: cve:CVE-2026-54893
swoosh
Source reference: /containers/cna/affected/0/product
- Affected versions
- Not stated in this record
- Fixed versions
- Not stated in this record
- Prerequisites
- Not stated in this record
swoosh
Source reference: /containers/cna/affected/1/product
- Affected versions
- Not stated in this record
- Fixed versions
- Not stated in this record
- Prerequisites
- Not stated in this record
Structured affected-version data
Original package identities and version rules from this source.
[
{
"cpes": [
"cpe:2.3:a:swoosh:swoosh:*:*:*:*:*:*:*:*"
],
"repo": "https://github.com/swoosh/swoosh",
"vendor": "swoosh",
"modules": [
"'Elixir.Swoosh.Adapters.MsGraph'"
],
"product": "swoosh",
"versions": [
{
"status": "affected",
"version": "1.12.0",
"lessThan": "1.26.3",
"versionType": "semver"
}
],
"packageURL": "pkg:hex/swoosh",
"packageName": "swoosh",
"programFiles": [
"lib/swoosh/adapters/ms_graph.ex"
],
"collectionURL": "https://repo.hex.pm",
"defaultStatus": "unaffected",
"programRoutines": [
{
"name": "'Elixir.Swoosh.Adapters.MsGraph':deliver/2"
},
{
"name": "'Elixir.Swoosh.Adapters.MsGraph':api_endpoint_url/2"
}
]
},
{
"cpes": [
"cpe:2.3:a:swoosh:swoosh:*:*:*:*:*:*:*:*"
],
"repo": "https://github.com/swoosh/swoosh",
"vendor": "swoosh",
"modules": [
"'Elixir.Swoosh.Adapters.MsGraph'"
],
"product": "swoosh",
"versions": [
{
"status": "affected",
"version": "23bfcdab71aee4613858ba6d116bb3311b72aa58",
"lessThan": "e38235453e81d1727bfc8d91e69ec4cb211ccf61",
"versionType": "git"
}
],
"packageURL": "pkg:github/swoosh/swoosh",
"packageName": "swoosh/swoosh",
"programFiles": [
"lib/swoosh/adapters/ms_graph.ex"
],
"collectionURL": "https://github.com",
"defaultStatus": "unaffected",
"programRoutines": [
{
"name": "'Elixir.Swoosh.Adapters.MsGraph':deliver/2"
},
{
"name": "'Elixir.Swoosh.Adapters.MsGraph':api_endpoint_url/2"
}
]
}
]- Related CVEs
- CVE-2026-54893
Source reference:
/cveMetadata/cveId
Publisher severity
low
Source reference: /containers/cna/metrics
- Event
- #1934 · Revision 1
- Added to Heist Feed
- Publisher date