mirror of
https://github.com/calebstewart/pwncat.git
synced 2024-11-23 17:15:38 +01:00
Added try-except for processing grep output
Ensured that errors were handled properly during password enumeration.
This commit is contained in:
parent
e76a741add
commit
57809be2ee
@ -69,8 +69,18 @@ def enumerate() -> Generator[FactData, None, None]:
|
||||
continue
|
||||
if len(line) < 3:
|
||||
continue
|
||||
|
||||
# Grab the page
|
||||
path = line[0]
|
||||
lineno = int(line[1])
|
||||
|
||||
try:
|
||||
# Grab the line number
|
||||
lineno = int(line[1])
|
||||
except ValueError:
|
||||
# Malformed line from grep, ignore it.
|
||||
continue
|
||||
|
||||
# Grab the content
|
||||
content = ":".join(line[2:])
|
||||
|
||||
password = None
|
||||
|
Loading…
Reference in New Issue
Block a user