CVE-2024-40430: Withdrawn SFTPGo's JWT Implmentation Lacks Certain Vulnerability
MODERATECVE-2024-40430 is a MODERATE (CVSS 6.5) sftpgo's jwt implmentation lacks certain vulnerability (CWE-639: Authorization Bypass Through User-Controlled Key) affecting Withdrawn libraries in the Go ecosystem. The issue involves sftpgo's jwt implmentation lacks certain security measures. Remediation is available in the latest vendor maintenance releases.
CVE-2024-40430 at a Glance
Security Impact
CVSS: 6.5
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N).
How to Fix CVE-2024-40430
To remediate this vulnerability, upgrade all affected Withdrawn 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 github.com/drakkan/sftpgo/v2 to Latest secure release
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/drakkan/sftpgo/v2
How to Check if You Are Affected
To determine whether your application is affected by CVE-2024-40430, inspect your project dependencies for Withdrawn:
inspect dependencies for github.com/drakkan/sftpgo/v2
Analyze the terminal output to locate any version of Withdrawn in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), 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-639: Authorization Bypass Through User-Controlled Key, where the system's authorization functionality does not prevent one user from gaining access to another user's data or record by modifying the key value identifying the data. In Withdrawn, 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-2024-40430 Affected Withdrawn Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/drakkan/sftpgo/v2
|
Go |
≤ 2.6.2
|
|
References
Frequently Asked Questions
What is CVE-2024-40430?
Which Withdrawn versions are affected?
What version fixes CVE-2024-40430?
Is github.com/drakkan/sftpgo/v2 affected?
What is the CVSS score of CVE-2024-40430?
What CWE is associated with CVE-2024-40430?
How can I check Go dependencies for CVE-2024-40430?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-x72p-g37q-4xr9",
"modified" : "2024-07-31T18:42:56Z",
"published" : "2024-07-22T09:31:55Z",
"withdrawn" : "2024-07-31T18:42:56Z",
"aliases" : [ "CVE-2024-40430" ],
"summary" : "Withdrawn: SFTPGo's JWT implmentation lacks certain security measures",
"details" : "Withdrawn:\nThe attack vector described in the backing report required that an attacker gain access to a user's session cookie. By gaining access to the session cookie the attacker is for all intents and purposes the valid user and any access to user data would be expected.\n\n~In SFTPGo 2.6.2, the JWT implementation lacks certain security measures, such as using JWT ID (JTI) claims, nonces, and proper expiration and invalidation mechanisms.~",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:H/A:N"
}, {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/drakkan/sftpgo/v2"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"last_affected" : "2.6.2"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2024-40430"
}, {
"type" : "WEB",
"url" : "https://github.com/github/advisory-database/pull/4645"
}, {
"type" : "WEB",
"url" : "https://alexsecurity.rocks/posts/cve-2024-40430"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/drakkan/sftpgo"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-323", "CWE-639" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2024-07-22T18:46:59Z",
"nvd_published_at" : "2024-07-22T07:15:02Z"
}
}