{"id":"GHSA-fg4q-ccq8-3r5q","revision":null,"records":[{"revision":"6c9d209e4f7949c184da474d1ba07971","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2024-39677","aliases":[],"title":"NHibernate SQL injection vulnerability in discriminator mappings, static fields referenced in HQL, and some utilities","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.","state":0,"publishedAt":"2024-07-08T14:52:39.053+00:00","modifiedAt":"2024-08-02T04:26:15.958+00:00","affected":[{"ecosystem":"Vendor product","name":"nhibernate-core","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"nhibernate\",\n                    \"product\": \"nhibernate-core\",\n                    \"versions\": [\n                        {\n                            \"version\": \"< 5.4.9\",\n                            \"status\": \"affected\"\n                        },\n                        {\n                            \"version\": \">= 5.5.0, < 5.5.2\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N","score":5.9,"severity":"MEDIUM"}],"references":["https://github.com/nhibernate/nhibernate-core/security/advisories/GHSA-fg4q-ccq8-3r5q","https://github.com/nhibernate/nhibernate-core/issues/3516","https://github.com/nhibernate/nhibernate-core/pull/3517","https://github.com/nhibernate/nhibernate-core/pull/3547","https://github.com/nhibernate/nhibernate-core/commit/b4a69d1a5ff5744312478d70308329af496e4ba9"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2024-39677","license":"CVE Program Terms of Use","key":"cve-program:CVE-2024-39677","identifiers":["CVE-2024-39677"]},"retained":false,"historicalAffected":[]},{"revision":"73e2e9c6467b4f7ca269af07d493f9b0","observedAt":"2026-11-15T02:31:01.57+00:00","statement":{"source":"euvd","id":"EUVD-2024-2335","aliases":["CVE-2024-39677","GHSA-fg4q-ccq8-3r5q"],"title":"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 mapp…","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.","state":0,"publishedAt":null,"modifiedAt":null,"affected":[],"metrics":[{"system":"EUVD CVSS 3.1","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N","score":5.9,"severity":null}],"references":["https://github.com/nhibernate/nhibernate-core/security/advisories/GHSA-fg4q-ccq8-3r5q","https://github.com/nhibernate/nhibernate-core/issues/3516","https://github.com/nhibernate/nhibernate-core/pull/3517","https://github.com/nhibernate/nhibernate-core/pull/3547","https://github.com/nhibernate/nhibernate-core/commit/b4a69d1a5ff5744312478d70308329af496e4ba9"],"sourceUrl":"https://euvd.enisa.europa.eu/vulnerability/EUVD-2024-2335","license":"ENISA EUVD · source terms and attribution apply","enrichment":{"sourceStatus":null,"weaknesses":[],"productCriteria":[],"sourceDates":{"datePublished":"Jul 8, 2024, 2:52:39 PM","dateUpdated":"Aug 2, 2024, 4:26:15 AM"},"relatedAdvisories":[],"note":"EUVD source date text has no stated timezone and is retained without inventing a UTC instant. Related bulletin membership is not an alias, common cause or applicability claim. A missing vector with a zero score is treated as unrated. Complete vendor/product and underlying source evidence remains in the original JSON."},"key":"euvd:EUVD-2024-2335","identifiers":["EUVD-2024-2335","CVE-2024-39677","GHSA-fg4q-ccq8-3r5q"]},"retained":false,"historicalAffected":[]},{"revision":"af7085b699a84e288271618f40a1c96e","observedAt":"2026-10-25T00:17:22.831+00:00","statement":{"source":"nvd","id":"CVE-2024-39677","aliases":[],"title":"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 mapp…","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.","state":0,"publishedAt":"2024-07-08T15:15:22.45+00:00","modifiedAt":"2026-06-17T07:42:26.68+00:00","affected":[],"metrics":[{"system":"CVSS 3.1 · security-advisories@github.com · Secondary","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N","score":5.9,"severity":"MEDIUM"},{"system":"CVSS 3.1 · nvd@nist.gov · Primary","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","score":9.8,"severity":"CRITICAL"}],"references":["https://github.com/nhibernate/nhibernate-core/commit/b4a69d1a5ff5744312478d70308329af496e4ba9","https://github.com/nhibernate/nhibernate-core/issues/3516","https://github.com/nhibernate/nhibernate-core/pull/3517","https://github.com/nhibernate/nhibernate-core/pull/3547","https://github.com/nhibernate/nhibernate-core/security/advisories/GHSA-fg4q-ccq8-3r5q"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2024-39677","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Modified","weaknesses":["CWE-89"],"productCriteria":["cpe:2.3:a:nhibernate:nhibernate-core:*:*:*:*:*:*:*:*"],"sourceDates":{"published":"2024-07-08T15:15:22.450","lastModified":"2026-06-17T07:42:26.680"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2024-39677","identifiers":["CVE-2024-39677"]},"retained":false,"historicalAffected":[]},{"revision":"5383f5b3a65045039cc6e4338245df9d","observedAt":"2026-10-23T16:01:25.029+00:00","statement":{"source":"osv","id":"GHSA-fg4q-ccq8-3r5q","aliases":["CVE-2024-39677"],"title":"NHibernate SQL injection vulnerability in discriminator mappings, static fields referenced in HQL, and some utilities","description":"### Impact\nA SQL injection vulnerability exists in some types implementing `ILiteralType.ObjectToSQLString`. Callers of these methods are exposed to the vulnerability, which includes:\n - Mappings using inheritance with discriminator values:\n   - The discriminator value could be written in the mapping in a way exploiting the vulnerability of the associated discriminator type, if that type is among the vulnerable ones.\n   - The current culture settings for formatting the discriminator value type could be altered in a way resulting into SQL injections with the discriminator values.\n - HQL queries referencing a static field of the application.\n - Users of the `SqlInsertBuilder` and `SqlUpdateBuilder` utilities, calling their `AddColumn` overload taking a literal value. These overloads are unused by NHibernate but could be used by users referencing directly these utilities.\n - Any direct use of the `ObjectToSQLString` methods for building SQL queries on the user side.\n\n### Patches\nReleases 5.4.9 and 5.5.2.\n\n### Workarounds\n - Ensure the application does not use the features listed above.\n - For discriminator usages, ensure the discriminator values in the mappings do not contain quotes for string discriminators. Furthermore, for types which `ToString` conversion can be altered to include SQL injections through adequate hacking of the current culture settings, either change for another type, or ensure the used values cannot allow culture exploits, or ensure the application performs sanity checks of the current culture settings. Types sensitive to culture include integers for negative values, dates, times and datetimes, floats and decimals.\n\n### References\n - https://github.com/nhibernate/nhibernate-core/issues/3516\n - https://github.com/nhibernate/nhibernate-core/pull/3517\n - https://github.com/nhibernate/nhibernate-core/pull/3547 ","state":0,"publishedAt":"2024-07-08T14:20:33+00:00","modifiedAt":"2026-09-10T03:50:16.9217287+00:00","affected":[{"ecosystem":"NuGet","name":"NHibernate","ranges":[{"type":"ECOSYSTEM","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"5.4.9"}]}],"versions":["2.1.2.4000","3.0.0.2001","3.0.0.3001","3.0.0.4000","3.1.0.4000","3.2.0.1001","3.2.0.1002","3.2.0.1003","3.2.0.2001","3.2.0.2002","3.2.0.3001","3.2.0.4000","3.3.0-CR1","3.3.0.4000","3.3.1.4000","3.3.2.4000","3.3.3-CR1","3.3.3.4000","3.3.3.4001","3.3.4.4000","3.3.5.4000","3.4.0-CR1","3.4.0.4000","3.4.1.4000","4.0.0-Alpha1","4.0.0-Alpha2","4.0.0-CR1","4.0.0.4000","4.0.1.4000","4.0.2.4000","4.0.3.4000","4.0.4.4000","4.1.0-CR1","4.1.0.4000","4.1.1.4000","4.1.2.4000","5.0.0","5.0.1","5.0.2","5.0.3","5.0.4","5.0.5","5.0.6","5.0.7","5.0.8","5.1.0","5.1.1","5.1.2","5.1.3","5.1.4","5.1.5","5.1.6","5.1.7","5.2.0","5.2.1","5.2.2","5.2.3","5.2.4","5.2.5","5.2.6","5.2.7","5.3.0","5.3.1","5.3.10","5.3.11","5.3.12","5.3.13","5.3.14","5.3.15","5.3.16","5.3.17","5.3.18","5.3.19","5.3.2","5.3.20","5.3.3","5.3.4","5.3.5","5.3.6","5.3.7","5.3.8","5.3.9","5.4.0","5.4.1","5.4.2","5.4.3","5.4.4","5.4.5","5.4.6","5.4.7","5.4.8"],"rawVersionEvidence":null},{"ecosystem":"NuGet","name":"NHibernate","ranges":[{"type":"ECOSYSTEM","events":[{"kind":"introduced","version":"5.5.0"},{"kind":"fixed","version":"5.5.2"}]}],"versions":["5.5.0","5.5.1"],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V3","vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:H/A:N","score":null,"severity":null},{"system":"CVSS_V4","vector":"CVSS:4.0/AV:N/AC:H/AT:N/PR:N/UI:N/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"HIGH"}],"references":["https://github.com/nhibernate/nhibernate-core/security/advisories/GHSA-fg4q-ccq8-3r5q","https://nvd.nist.gov/vuln/detail/CVE-2024-39677","https://github.com/nhibernate/nhibernate-core/issues/3516","https://github.com/nhibernate/nhibernate-core/pull/3517","https://github.com/nhibernate/nhibernate-core/pull/3547","https://github.com/nhibernate/nhibernate-core/commit/b4a69d1a5ff5744312478d70308329af496e4ba9","https://github.com/nhibernate/nhibernate-core"],"sourceUrl":"https://github.com/advisories/GHSA-fg4q-ccq8-3r5q","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-fg4q-ccq8-3r5q","identifiers":["GHSA-fg4q-ccq8-3r5q","CVE-2024-39677"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-11-16T13:44:52.2477779+00:00","complete":true,"records":1781,"lastAttemptAt":"2026-11-16T13:44:52.2477779+00:00","lastSuccessAt":"2026-11-16T13:44:52.547205+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:52.5472072+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-6be044d0e08779dadd136f949a536de4047af96f5d7bceb7e190ecffbb8f18ca-0b8d08d891bfa11c0d58a73df578d0b4ffb15504346bf16dc0ebf0fd9e417816","complete":true,"records":425990,"lastAttemptAt":"2026-11-16T13:44:51.1421919+00:00","lastSuccessAt":"2026-11-16T13:44:51.096163+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:51.1421919+00:00","snapshotPublishedAt":"2026-11-16T13:33:35+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-e7b8d43557f44ad0b4e0a87d8bc9833b","complete":true,"records":13821,"lastAttemptAt":"2026-11-16T13:45:32.4445669+00:00","lastSuccessAt":"2026-11-16T13:45:32.439+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:45:32.439+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13874,"expectedIdentifiers":13874,"failedIdentifiers":0},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-11-16T13:44:52.2477779+00:00","complete":true,"records":1125,"lastAttemptAt":"2026-11-16T13:44:52.2477779+00:00","lastSuccessAt":"2026-11-16T13:44:52.6938042+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:52.6938064+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-35f0b78ccc2a41d095ad714d95a22e02","complete":false,"records":13833,"lastAttemptAt":"2026-11-16T13:45:26.5787483+00:00","lastSuccessAt":"2026-11-16T13:45:26.575+00:00","error":"400 identifier lookups failed; latest failures include HttpError (HTTP 503). Other identifiers were checked independently.","lastVerifiedAt":"2026-11-16T13:45:26.575+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13474,"expectedIdentifiers":13874,"failedIdentifiers":400},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-64eea06dbd27de8464d5dbce1b78cc794cc59e2d901516ae0d3ea76e624cdae0","complete":true,"records":9955,"lastAttemptAt":"2026-11-16T13:44:51.7855064+00:00","lastSuccessAt":"2026-11-14T13:57:23.1208135+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:51.7855064+00:00","snapshotPublishedAt":"2026-11-14T13:17:57+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-f4424d7d4861b1af1404bd15abcb83f295dcd003412a9340ca99dc8200aa148a","complete":true,"records":2014,"lastAttemptAt":"2026-11-16T13:44:51.1886417+00:00","lastSuccessAt":"2026-11-13T19:57:08.2864435+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:51.1886417+00:00","snapshotPublishedAt":"2026-11-13T19:33:10+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-6086d649bcb454cdf302d7d9275177bda73550e1b6e446b3520e9b6266d3582c","complete":true,"records":3148,"lastAttemptAt":"2026-11-16T13:44:52.214417+00:00","lastSuccessAt":"2026-11-15T11:05:17.1034234+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:52.214417+00:00","snapshotPublishedAt":"2026-11-15T10:03:04+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-263d9c8d63997345727b11314d9b9377eba9fd4146f04497c069a15e332b60cb","complete":true,"records":232482,"lastAttemptAt":"2026-11-16T13:44:51.6814212+00:00","lastSuccessAt":"2026-11-16T07:32:30.5701252+00:00","error":null,"lastVerifiedAt":"2026-11-16T13:44:51.6814212+00:00","snapshotPublishedAt":"2026-11-16T06:48:00+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null,"failedIdentifiers":null}]}