]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-41712: Avoid runaway regex match in upload scripts (GH-23166)
authorYash Shete <universeyash4@gmail.com>
Mon, 9 Nov 2020 17:38:09 +0000 (23:08 +0530)
committerGitHub <noreply@github.com>
Mon, 9 Nov 2020 17:38:09 +0000 (17:38 +0000)
Tools/msi/purge.py

index a8b8f4d8973c40490ad84c09da4a80c7f9f764b9..27b6b054a445ad33dc321ee53b098b577089efe7 100644 (file)
@@ -12,7 +12,7 @@ import sys
 
 from urllib.request import *
 
-VERSION_RE = re.compile(r'(\d+\.\d+\.\d+)(\w+\d+)?$')
+VERSION_RE = re.compile(r'(\d+\.\d+\.\d+)([A-Za-z_]+\d+)?$')
 
 try:
     m = VERSION_RE.match(sys.argv[1])