{
    "CVE_data_meta": {
        "ASSIGNER": "security-advisories@github.com",
        "ID": "CVE-2021-37706",
        "STATE": "PUBLIC",
        "TITLE": "Potential integer underflow upon receiving STUN message in PJSIP"
    },
    "affects": {
        "vendor": {
            "vendor_data": [
                {
                    "product": {
                        "product_data": [
                            {
                                "product_name": "pjproject",
                                "version": {
                                    "version_data": [
                                        {
                                            "version_value": "<= 2.11.1"
                                        }
                                    ]
                                }
                            }
                        ]
                    },
                    "vendor_name": "pjsip"
                }
            ]
        }
    },
    "data_format": "MITRE",
    "data_type": "CVE",
    "data_version": "4.0",
    "description": {
        "description_data": [
            {
                "lang": "eng",
                "value": "PJSIP is a free and open source multimedia communication library written in C language implementing standard based protocols such as SIP, SDP, RTP, STUN, TURN, and ICE. In affected versions if the incoming STUN message contains an ERROR-CODE attribute, the header length is not checked before performing a subtraction operation, potentially resulting in an integer underflow scenario. This issue affects all users that use STUN. A malicious actor located within the victim\u2019s network may forge and send a specially crafted UDP (STUN) message that could remotely execute arbitrary code on the victim\u2019s machine. Users are advised to upgrade as soon as possible. There are no known workarounds."
            }
        ]
    },
    "impact": {
        "cvss": {
            "attackComplexity": "LOW",
            "attackVector": "NETWORK",
            "availabilityImpact": "LOW",
            "baseScore": 7.3,
            "baseSeverity": "HIGH",
            "confidentialityImpact": "LOW",
            "integrityImpact": "LOW",
            "privilegesRequired": "NONE",
            "scope": "UNCHANGED",
            "userInteraction": "NONE",
            "vectorString": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:L",
            "version": "3.1"
        }
    },
    "problemtype": {
        "problemtype_data": [
            {
                "description": [
                    {
                        "lang": "eng",
                        "value": "CWE-191: Integer Underflow (Wrap or Wraparound)"
                    }
                ]
            }
        ]
    },
    "references": {
        "reference_data": [
            {
                "name": "https://github.com/pjsip/pjproject/security/advisories/GHSA-2qpg-f6wf-w984",
                "refsource": "CONFIRM",
                "url": "https://github.com/pjsip/pjproject/security/advisories/GHSA-2qpg-f6wf-w984"
            },
            {
                "name": "https://github.com/pjsip/pjproject/commit/15663e3f37091069b8c98a7fce680dc04bc8e865",
                "refsource": "MISC",
                "url": "https://github.com/pjsip/pjproject/commit/15663e3f37091069b8c98a7fce680dc04bc8e865"
            },
            {
                "refsource": "FULLDISC",
                "name": "20220304 AST-2022-004: pjproject: integer underflow on STUN message",
                "url": "http://seclists.org/fulldisclosure/2022/Mar/0"
            },
            {
                "refsource": "MISC",
                "name": "http://packetstormsecurity.com/files/166225/Asterisk-Project-Security-Advisory-AST-2022-004.html",
                "url": "http://packetstormsecurity.com/files/166225/Asterisk-Project-Security-Advisory-AST-2022-004.html"
            },
            {
                "refsource": "MLIST",
                "name": "[debian-lts-announce] 20220328 [SECURITY] [DLA 2962-1] pjproject security update",
                "url": "https://lists.debian.org/debian-lts-announce/2022/03/msg00035.html"
            },
            {
                "refsource": "GENTOO",
                "name": "GLSA-202210-37",
                "url": "https://security.gentoo.org/glsa/202210-37"
            },
            {
                "refsource": "MLIST",
                "name": "[debian-lts-announce] 20221117 [SECURITY] [DLA 3194-1] asterisk security update",
                "url": "https://lists.debian.org/debian-lts-announce/2022/11/msg00021.html"
            },
            {
                "refsource": "DEBIAN",
                "name": "DSA-5285",
                "url": "https://www.debian.org/security/2022/dsa-5285"
            },
            {
                "refsource": "MLIST",
                "name": "[debian-lts-announce] 20230829 [SECURITY] [DLA 3549-1] ring security update",
                "url": "https://lists.debian.org/debian-lts-announce/2023/08/msg00038.html"
            }
        ]
    },
    "source": {
        "advisory": "GHSA-2qpg-f6wf-w984",
        "discovery": "UNKNOWN"
    }
}