CVE-2024-39677
NHibernate SQL injection vulnerability in discriminator mappings, static fields referenced in HQL, and some utilities
- 5.9MediumCVSS base score
- 0.58%Exploitation in 30 daysEPSS · top 52% of all CVEs
- NoKnown exploitednot in CISA's KEV catalog
- NonePublic exploitsnone known yet
Description
NHibernate is an object-relational mapper for the .NET framework. A SQL injection vulnerability exists in some types implementing ILiteralType.ObjectToSQLString. Callers of these methods are exposed to the vulnerability, which includes mappings using inheritance with discriminator values; HQL queries referencing a static field of the application; users of the SqlInsertBuilder and SqlUpdateBuilder utilities, calling their AddColumn overload taking a literal value; and any direct use of the ObjectToSQLString methods for building SQL queries on the user side. This vulnerability is fixed in 5.4.9 and 5.5.2.
Timeline
ID reserved
By GitHub_M
- 11 days later
· 11 days later
Published
- 25 days later
· 25 days later
Record updated
Changes after publication (a new score, a public exploit, EPSS crossing 1, 10 or 50 %, leaving KEV) are kept since November 2026; earlier ones are not known.
Scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| GitHub_MCNA (assigner) | 3.1 | Medium5.9 | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N |
| NVDNVD · Modified | 3.1 | Critical9.8 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H |
- EPSS (exploitation in 30 days)
- 0.58% · top 52% of all CVEs (11 Nov 2026)
- CISA SSVC
- Exploitation: none · Automatable: no · Technical impact: partial
The list uses the assigner's score when there is one, then CISA's, then NVD's: Medium 5.9.
Affected products
- affected < 5.4.9
- affected >= 5.5.0, < 5.5.2
Affected packages
From reviewed advisories of the GitHub Advisory Database.
- NuGetNHibernateGHSA-fg4q-ccq8-3r5q (opens in a new tab)
References
References5
- https://github.com/nhibernate/nhibernate-core/security/advisories/GHSA-fg4q-ccq8-3r5q (opens in a new tab)x_refsource_CONFIRMx_transferred
- https://github.com/nhibernate/nhibernate-core/issues/3516 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/nhibernate/nhibernate-core/pull/3517 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/nhibernate/nhibernate-core/pull/3547 (opens in a new tab)x_refsource_MISCx_transferred
- https://github.com/nhibernate/nhibernate-core/commit/b4a69d1a5ff5744312478d70308329af496e4ba9 (opens in a new tab)x_refsource_MISCx_transferred
Sources
The same CVE in the primary databases and aggregators, to check against.
- CVE.org record (opens in a new tab)
- CVE List JSON (GitHub) (opens in a new tab)
- NVD (opens in a new tab)
- FIRST EPSS (opens in a new tab)
- EUVD EUVD-2024-2335 (opens in a new tab)
- OSV.dev (opens in a new tab)
- GitHub Advisory GHSA-fg4q-ccq8-3r5q (opens in a new tab)
- CIRCL Vulnerability-Lookup (opens in a new tab)
Badge for a README or a ticket
[](https://cveledger.app/cve/CVE-2024-39677)Record last updated .