Логотип exploitDog
Консоль
Логотип exploitDog

exploitDog

redhat логотип

CVE-2021-32839

Опубликовано: 10 сент. 2021
Источник: redhat
CVSS3: 7.5

Описание

sqlparse is a non-validating SQL parser module for Python. In sqlparse versions 0.4.0 and 0.4.1 there is a regular Expression Denial of Service in sqlparse vulnerability. The regular expression may cause exponential backtracking on strings containing many repetitions of '\r\n' in SQL comments. Only the formatting feature that removes comments from SQL statements is affected by this regular expression. As a workaround don't use the sqlformat.format function with keyword strip_comments=True or the --strip-comments command line flag when using the sqlformat command line tool. The issues has been fixed in sqlparse 0.4.2.

A resource-consumption flaw was found in python-sqlparse. The formatter function that strips comments from SQL contains a regular expression that is vulnerable to Regular Expression Denial of Service (ReDoS). A network attacker could craft an SQL comment containing numerous repetitions of '\r\n' that could cause exponential backtracking and cause the system to hang.

Меры по смягчению последствий

As mitigation, don't use the sqlformat.format function with keyword strip_comments=True or the --strip-comments command line flag when using the sqlformat command line tool.

Затронутые пакеты

ПлатформаПакетСостояниеРекомендацияРелиз
Red Hat Ansible Automation Platform 1.2python-sqlparseAffected
Red Hat Ansible Automation Platform 1.2sqlparseAffected
Red Hat Ansible Tower 3sqlparseOut of support scope
Red Hat OpenStack Platform 10 (Newton)python-sqlparseOut of support scope
Red Hat OpenStack Platform 13 (Queens)python-sqlparseOut of support scope
Red Hat OpenStack Platform 16.1python-sqlparseNot affected
Red Hat OpenStack Platform 16.2python-sqlparseNot affected
Red Hat Satellite 6.11 for RHEL 8python-sqlparseFixedRHSA-2022:549805.07.2022
Red Hat Satellite 6.11 for RHEL 8python-sqlparseFixedRHSA-2022:549805.07.2022

Показывать по

Дополнительная информация

Статус:

Moderate
Дефект:
CWE-400
https://bugzilla.redhat.com/show_bug.cgi?id=2005072python-sqlparse: ReDoS via regular expression in StripComments filter

7.5 High

CVSS3

Связанные уязвимости

CVSS3: 7.5
ubuntu
больше 4 лет назад

sqlparse is a non-validating SQL parser module for Python. In sqlparse versions 0.4.0 and 0.4.1 there is a regular Expression Denial of Service in sqlparse vulnerability. The regular expression may cause exponential backtracking on strings containing many repetitions of '\r\n' in SQL comments. Only the formatting feature that removes comments from SQL statements is affected by this regular expression. As a workaround don't use the sqlformat.format function with keyword strip_comments=True or the --strip-comments command line flag when using the sqlformat command line tool. The issues has been fixed in sqlparse 0.4.2.

CVSS3: 7.5
nvd
больше 4 лет назад

sqlparse is a non-validating SQL parser module for Python. In sqlparse versions 0.4.0 and 0.4.1 there is a regular Expression Denial of Service in sqlparse vulnerability. The regular expression may cause exponential backtracking on strings containing many repetitions of '\r\n' in SQL comments. Only the formatting feature that removes comments from SQL statements is affected by this regular expression. As a workaround don't use the sqlformat.format function with keyword strip_comments=True or the --strip-comments command line flag when using the sqlformat command line tool. The issues has been fixed in sqlparse 0.4.2.

CVSS3: 7.5
debian
больше 4 лет назад

sqlparse is a non-validating SQL parser module for Python. In sqlparse ...

suse-cvrf
около 4 лет назад

Security update for python-sqlparse

suse-cvrf
около 4 лет назад

Security update for python-sqlparse

7.5 High

CVSS3