mirror of
https://github.com/mgeeky/decode-spam-headers.git
synced 2024-11-22 02:21:37 +01:00
Fix for issues/9
This commit is contained in:
parent
2eec0b5f47
commit
492b6e7444
@ -5645,7 +5645,11 @@ Src: https://www.cisco.com/c/en/us/td/docs/security/esa/esa11-1/user_guide/b_ESA
|
|||||||
if num != -1:
|
if num != -1:
|
||||||
num1 += 1
|
num1 += 1
|
||||||
|
|
||||||
value = value.replace('<', '').replace('>', '').replace('\t', '').replace(' ', '').strip()
|
m = re.search(r'([\w\._\+-]+@([\w.-]+\.)+[\w]{2,})', value, re.I)
|
||||||
|
if m:
|
||||||
|
value = m.group(1)
|
||||||
|
else:
|
||||||
|
value = value.replace('<', '').replace('>', '').replace('\t', '').replace(' ', '').strip()
|
||||||
|
|
||||||
headers += f' - {hdr}\n'
|
headers += f' - {hdr}\n'
|
||||||
values += f' - {value}\n'
|
values += f' - {value}\n'
|
||||||
@ -6431,7 +6435,8 @@ This can lead to an internal information disclosure. This test shows potential h
|
|||||||
}
|
}
|
||||||
|
|
||||||
def testResolveIntoIP(self):
|
def testResolveIntoIP(self):
|
||||||
domains = set(re.findall(r'([a-z0-9_\-\.]+\.[a-zA-Z]{2,5})', self.text, re.I))
|
#domains = set(re.findall(r'([a-z0-9_\-\.]+\.[a-zA-Z]{2,})', self.text, re.I))
|
||||||
|
domains = set(re.findall(r'((?:[\w.-]+\.)+[\w]{2,})', self.text, re.I))
|
||||||
resolved = set()
|
resolved = set()
|
||||||
result = ''
|
result = ''
|
||||||
tmp = ''
|
tmp = ''
|
||||||
@ -6449,6 +6454,8 @@ This can lead to an internal information disclosure. This test shows potential h
|
|||||||
if d in resolved: continue
|
if d in resolved: continue
|
||||||
if d in skip: continue
|
if d in skip: continue
|
||||||
|
|
||||||
|
if f'{d}@' in self.text: continue
|
||||||
|
|
||||||
try:
|
try:
|
||||||
resolved.add(d)
|
resolved.add(d)
|
||||||
d2 = self.colorizeKeywords(d)
|
d2 = self.colorizeKeywords(d)
|
||||||
|
Loading…
Reference in New Issue
Block a user