fixed 'SyntaxWarning: invalid escape sequence' for Python 3.12+

This commit is contained in:
exploide 2023-12-14 18:20:04 +01:00
parent 4ea3d7b765
commit e9bd8a43ef
4 changed files with 6 additions and 6 deletions

2
packets.py Executable file → Normal file
View file

@ -215,7 +215,7 @@ class DNS_SRV_Ans(Packet):
def calculate(self,data):
self.fields["Tid"] = data[0:2]
DNSName = ''.join(data[12:].split('\x00')[:1])
SplitFQDN = re.split('\W+', DNSName) # split the ldap.tcp.blah.blah.blah.domain.tld
SplitFQDN = re.split(r'\W+', DNSName) # split the ldap.tcp.blah.blah.blah.domain.tld
#What's the question? we need it first to calc all other len.
self.fields["QuestionName"] = DNSName