{"id":"UBUNTU-CVE-2021-45958","details":"UltraJSON (aka ujson) through 5.1.0 has a stack-based buffer overflow in Buffer_AppendIndentUnchecked (called from encode). Exploitation can, for example, use a large amount of indentation.","modified":"2026-05-20T16:06:30.794456166Z","published":"2022-01-01T00:15:00Z","related":["USN-6629-1","USN-6629-2"],"upstream":["CVE-2021-45958"],"references":[{"type":"REPORT","url":"https://ubuntu.com/security/CVE-2021-45958"},{"type":"REPORT","url":"https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=36009"},{"type":"REPORT","url":"https://github.com/google/oss-fuzz-vulns/blob/main/vulns/ujson/OSV-2021-955.yaml"},{"type":"ADVISORY","url":"https://ubuntu.com/security/notices/USN-6629-1"},{"type":"ADVISORY","url":"https://ubuntu.com/security/notices/USN-6629-2"},{"type":"REPORT","url":"https://www.cve.org/CVERecord?id=CVE-2021-45958"}],"affected":[{"package":{"name":"pandas","ecosystem":"Ubuntu:14.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=trusty"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.12.0-2ubuntu1","0.13.1-2ubuntu1","0.13.1-2ubuntu2"],"ecosystem_specific":{"binaries":[{"binary_version":"0.13.1-2ubuntu2","binary_name":"python-pandas"},{"binary_name":"python-pandas-lib","binary_version":"0.13.1-2ubuntu2"},{"binary_name":"python3-pandas","binary_version":"0.13.1-2ubuntu2"},{"binary_version":"0.13.1-2ubuntu2","binary_name":"python3-pandas-lib"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"ujson","ecosystem":"Ubuntu:Pro:16.04:LTS","purl":"pkg:deb/ubuntu/ujson?arch=source&distro=esm-apps%2Fxenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.33-1ubuntu0.1~esm2"}]}],"versions":["1.33-1","1.33-1build1"],"ecosystem_specific":{"availability":"Available with Ubuntu Pro: https://ubuntu.com/pro","binaries":[{"binary_version":"1.33-1ubuntu0.1~esm2","binary_name":"python-ujson"},{"binary_version":"1.33-1ubuntu0.1~esm2","binary_name":"python3-ujson"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:16.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=xenial"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.15.0-2","0.15.0-2ubuntu1","0.15.0-2ubuntu2","0.17.1-3ubuntu2"],"ecosystem_specific":{"binaries":[{"binary_name":"python-pandas","binary_version":"0.17.1-3ubuntu2"},{"binary_version":"0.17.1-3ubuntu2","binary_name":"python-pandas-lib"},{"binary_name":"python3-pandas","binary_version":"0.17.1-3ubuntu2"},{"binary_name":"python3-pandas-lib","binary_version":"0.17.1-3ubuntu2"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:18.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=bionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.19.2-5.1ubuntu4","0.22.0-2ubuntu1","0.22.0-3","0.22.0-4","0.22.0-4ubuntu1"],"ecosystem_specific":{"binaries":[{"binary_version":"0.22.0-4ubuntu1","binary_name":"python-pandas"},{"binary_name":"python-pandas-lib","binary_version":"0.22.0-4ubuntu1"},{"binary_name":"python3-pandas","binary_version":"0.22.0-4ubuntu1"},{"binary_name":"python3-pandas-lib","binary_version":"0.22.0-4ubuntu1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"ujson","ecosystem":"Ubuntu:Pro:18.04:LTS","purl":"pkg:deb/ubuntu/ujson?arch=source&distro=esm-apps%2Fbionic"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.35-2ubuntu0.1~esm1"}]}],"versions":["1.35-1build2","1.35-2"],"ecosystem_specific":{"binaries":[{"binary_name":"python-ujson","binary_version":"1.35-2ubuntu0.1~esm1"},{"binary_version":"1.35-2ubuntu0.1~esm1","binary_name":"python3-ujson"}],"availability":"Available with Ubuntu Pro: https://ubuntu.com/pro"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"ujson","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/ujson?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"1.35-4ubuntu0.1"}]}],"versions":["1.35-3build1","1.35-3build2","1.35-4","1.35-4build1"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-ujson","binary_version":"1.35-4ubuntu0.1"}],"availability":"No subscription required"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:20.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=focal"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["0.23.3+dfsg-4ubuntu1","0.23.3+dfsg-4ubuntu5","0.23.3+dfsg-4ubuntu6","0.25.3+dfsg-4","0.25.3+dfsg-4build1","0.25.3+dfsg-7"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-pandas","binary_version":"0.25.3+dfsg-7"},{"binary_name":"python3-pandas-lib","binary_version":"0.25.3+dfsg-7"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:22.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=jammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.1.5+dfsg-2","1.1.5+dfsg-2ubuntu1","1.3.5+dfsg-2","1.3.5+dfsg-2ubuntu1","1.3.5+dfsg-3"],"ecosystem_specific":{"binaries":[{"binary_version":"1.3.5+dfsg-3","binary_name":"python3-pandas"},{"binary_version":"1.3.5+dfsg-3","binary_name":"python3-pandas-lib"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"ujson","ecosystem":"Ubuntu:Pro:22.04:LTS","purl":"pkg:deb/ubuntu/ujson?arch=source&distro=esm-apps%2Fjammy"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"5.1.0-1ubuntu0.1~esm1"}]}],"versions":["4.0.2-1","4.0.2-1build1","4.2.0-1","5.1.0-1","5.1.0-1build1"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-ujson","binary_version":"5.1.0-1ubuntu0.1~esm1"}],"availability":"Available with Ubuntu Pro: https://ubuntu.com/pro"},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:24.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=noble"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["1.5.3+dfsg-6","1.5.3+dfsg-6ubuntu1","1.5.3+dfsg-7ubuntu1","1.5.3+dfsg-10","2.1.4+dfsg-4ubuntu2","2.1.4+dfsg-7"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-pandas","binary_version":"2.1.4+dfsg-7"},{"binary_name":"python3-pandas-lib","binary_version":"2.1.4+dfsg-7"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:25.10","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=questing"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.2.3+dfsg-8build1","2.2.3+dfsg-9"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-pandas","binary_version":"2.2.3+dfsg-9"},{"binary_name":"python3-pandas-lib","binary_version":"2.2.3+dfsg-9"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}},{"package":{"name":"pandas","ecosystem":"Ubuntu:26.04:LTS","purl":"pkg:deb/ubuntu/pandas?arch=source&distro=resolute"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["2.2.3+dfsg-9","2.3.3+dfsg-1ubuntu1","2.3.3+dfsg-3","2.3.3+dfsg-3ubuntu1"],"ecosystem_specific":{"binaries":[{"binary_name":"python3-pandas","binary_version":"2.3.3+dfsg-3ubuntu1"},{"binary_name":"python3-pandas-lib","binary_version":"2.3.3+dfsg-3ubuntu1"}]},"database_specific":{"source":"https://github.com/canonical/ubuntu-security-notices/blob/main/osv/cve/2021/UBUNTU-CVE-2021-45958.json"}}],"schema_version":"1.7.5","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H"},{"type":"Ubuntu","score":"medium"}]}