Public mode

No access to your tenant or devices. Every item links to its source. What this means

Sources need attention Customize Public modeDiscuss ChangeIntel on Discord

nhibernate-core · SQL injection

CVSS 3.1 5.9 MEDIUMEUVD CVSS 3.1 5.9 CVSS 3.1 · [email protected] · Secondary 5.9 MEDIUMCVSS 3.1 · [email protected] · Primary 9.8 CRITICALCVSS_V3 CVSS_V4 Publisher rating HIGHFixed by NHibernate 5.4.9Fixed by NHibernate 5.5.2KEV status unknown

cve-program · CVE-2024-39677

Published

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.

Read the publisher's advisory

euvd · EUVD-2024-2335

Published

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.

Read the publisher's advisory

nvd · CVE-2024-39677

Published

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.

Read the publisher's advisory

osv · GHSA-fg4q-ccq8-3r5q

Published

### Impact 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: - 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. - The current culture settings for formatting the discriminator value type could be altered in a way resulting into SQL injections with the 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. These overloads are unused by NHibernate but could be used by users referencing directly these utilities. - Any direct use of the `ObjectToSQLString` methods for building SQL queries on the user side. ### Patches Releases 5.4.9 and 5.5.2. ### Workarounds - Ensure the application does not use the features listed above. - 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. ### References - https://github.com/nhibernate/nhibernate-core/issues/3516 - https://github.com/nhibernate/nhibernate-core/pull/3517 - https://github.com/nhibernate/nhibernate-core/pull/3547

Read the publisher's advisory

Affected versions, risk and source history

cve-program · CVE-2024-39677

Published

nhibernate-core

Vendor product

Publisher's version information

Shown as published. These rules are not interpreted as NuGet package version ranges.

{
                    "vendor": "nhibernate",
                    "product": "nhibernate-core",
                    "versions": [
                        {
                            "version": "< 5.4.9",
                            "status": "affected"
                        },
                        {
                            "version": ">= 5.5.0, < 5.5.2",
                            "status": "affected"
                        }
                    ]
                }

Original source record · Cite this exact observation · Complete original publisher JSON

euvd · EUVD-2024-2335

Published

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.

Original publisher date fields

datePublished: Jul 8, 2024, 2:52:39 PM

dateUpdated: Aug 2, 2024, 4:26:15 AM

No normalized affected-package data is projected for this source revision. The original publisher record may contain additional product and version evidence; this does not establish that a package is unaffected.

Original source record · Cite this exact observation · Complete original publisher JSON

nvd · CVE-2024-39677

Published

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.

Source analysis status: Modified

Weakness classifications: CWE-89

Original publisher date fields

published: 2024-07-08T15:15:22.450

lastModified: 2026-06-17T07:42:26.680

1 source CPE criteria · context only
  • cpe:2.3:a:nhibernate:nhibernate-core:*:*:*:*:*:*:*:*

The original JSON retains the logical configuration operators, exclusions and version bounds.

No normalized affected-package data is projected for this source revision. The original publisher record may contain additional product and version evidence; this does not establish that a package is unaffected.

Original source record · Cite this exact observation · Complete original publisher JSON

osv · GHSA-fg4q-ccq8-3r5q

Published

NHibernate

NuGet

ECOSYSTEM · introduced 0 → fixed 5.4.9

91 versions listed as affected

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

NHibernate

NuGet

ECOSYSTEM · introduced 5.5.0 → fixed 5.5.2

2 versions listed as affected

5.5.0, 5.5.1

Original source record · Cite this exact observation · Complete original publisher JSON

ChangeIntel

An IT change radar: releases, security, known issues, retirements, documentation changes, and service status from public sources. Every item links to supporting evidence; dates and statuses can change after they are read.

Sources read 16 Nov 14:56 UTC · 274 of 275 readable · 250 fully read · 20 waiting for GitHub's hourly limit · documentation 469/469 current