CVE-2024-2339

Source
https://nvd.nist.gov/vuln/detail/CVE-2024-2339
Import Source
https://storage.googleapis.com/osv-test-cve-osv-conversion/osv-output/CVE-2024-2339.json
JSON Data
https://api.test.osv.dev/v1/vulns/CVE-2024-2339
Published
2024-03-08T20:15:46.170Z
Modified
2025-11-15T15:39:04.283820Z
Severity
  • 8.8 (High) CVSS_V3 - CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H CVSS Calculator
Summary
[none]
Details

PostgreSQL Anonymizer v1.2 contains a vulnerability that allows a user who owns a table to elevate to superuser. A user can define a masking function for a column and place malicious code in that function. When a privileged user applies the masking rules using the static masking or the anonymous dump method, the malicious code is executed and can grant escalated privileges to the malicious user. PostgreSQL Anonymizer v1.2 does provide a protection against this risk with the restricttotrusted_schemas option, but that protection is incomplete. Users that don't own a table, especially masked users cannot exploit this vulnerability. The problem is resolved in v1.3.

References

Affected packages

Git / gitlab.com/dalibo/postgresql_anonymizer

Affected ranges

Type
GIT
Repo
https://gitlab.com/dalibo/postgresql_anonymizer
Events
Introduced
0 Unknown introduced commit / All previous commits are affected
Fixed

Affected versions

0.*

0.0.1
0.0.3
0.1.1
0.10.0
0.11.0
0.12.0
0.2.1
0.3.0
0.3.1
0.4.0
0.4.1
0.5.0
0.6.0
0.7.0
0.7.1
0.8.0
0.9.0

1.*

1.0.0
1.1.0
1.2.0

Database specific

vanir_signatures

[
    {
        "digest": {
            "function_hash": "245017833258323557132688328244474316270",
            "length": 283.0
        },
        "signature_type": "Function",
        "deprecated": false,
        "signature_version": "v1",
        "id": "CVE-2024-2339-3140e264",
        "target": {
            "file": "anon.c",
            "function": "pa_check_function"
        },
        "source": "https://gitlab.com/dalibo/postgresql_anonymizer@e517b38e62e50871b04011598e73a7308bdae9d9"
    },
    {
        "digest": {
            "threshold": 0.9,
            "line_hashes": [
                "321073502730422139872010215586289647746",
                "272742691637730728465839795598608607555",
                "297373680401104608792686110412660085964",
                "60955931290351324619274976056099176691",
                "39806432343466589931480560840667358983",
                "121984233576497820744753040803638188480",
                "188815773005558568085599158803575998376",
                "72727537404766280749557172849589715709",
                "101976449419796792959439226692199669241",
                "201595575409609410395131139049849575953",
                "330994438111034983287928144066968160964",
                "340106720611330770371077763362969871761",
                "48289121267494168704511276969143211653",
                "225964519246417454028196665367431200438",
                "331143666954720485447190705496432760227",
                "35479189929604833354943428618954110249",
                "49568909069773594939571590202075286727",
                "57712392358776786778603367197053330657"
            ]
        },
        "signature_type": "Line",
        "deprecated": false,
        "signature_version": "v1",
        "id": "CVE-2024-2339-682cfbcf",
        "target": {
            "file": "anon.c"
        },
        "source": "https://gitlab.com/dalibo/postgresql_anonymizer@e517b38e62e50871b04011598e73a7308bdae9d9"
    }
]