Skip to content

Commit

Permalink
Fix regex for comma seperated values
Browse files Browse the repository at this point in the history
WWW-Authenticate Header (for example `'algorithm=MD5,realm="local",nonce="11111111:222222aaaaaa333333bbbbbb44444"'`) is not parsed correctly in line 455. My proposed change resolves this problem.
  • Loading branch information
dermodmaster committed Sep 26, 2022
1 parent 170fe84 commit 283ee1c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pyVoIP/SIP.py
Original file line number Diff line number Diff line change
Expand Up @@ -341,7 +341,7 @@ def __init__(self, data: bytes):
self.body: Dict[str, Any] = {}
self.authentication: Dict[str, str] = {}
self.raw = data
self.auth_match = re.compile('(\w+)=("[^"]+"|[^ \t]+)')
self.auth_match = re.compile('(\w+)=("[^",]+"|[^ \t,]+)')
self.parse(data)

def summary(self) -> str:
Expand Down

0 comments on commit 283ee1c

Please sign in to comment.