mirror of
https://github.com/calebstewart/pwncat.git
synced 2024-11-24 01:25:37 +01:00
fix sudo timeout, fix set-password login, other exceptions
This commit is contained in:
parent
c2c83ca058
commit
b5ce7f52a4
@ -1783,7 +1783,8 @@ class Victim:
|
|||||||
):
|
):
|
||||||
|
|
||||||
if send_password and password is None:
|
if send_password and password is None:
|
||||||
self.client.send(util.CTRL_C)
|
self.client.send(util.CTRL_C*2)
|
||||||
|
self.flush_output()
|
||||||
raise PermissionError(f"{self.current_user.name}: no known password")
|
raise PermissionError(f"{self.current_user.name}: no known password")
|
||||||
|
|
||||||
self.flush_output()
|
self.flush_output()
|
||||||
@ -1808,6 +1809,11 @@ class Victim:
|
|||||||
raise PermissionError(
|
raise PermissionError(
|
||||||
f"{self.current_user.name}: incorrect password/permissions"
|
f"{self.current_user.name}: incorrect password/permissions"
|
||||||
)
|
)
|
||||||
|
else:
|
||||||
|
self.client.send(util.CTRL_C*2)
|
||||||
|
self.flush_output()
|
||||||
|
raise PermissionError(f"{self.current_user.name}: no known password")
|
||||||
|
|
||||||
|
|
||||||
if stream:
|
if stream:
|
||||||
return pipe
|
return pipe
|
||||||
|
Loading…
Reference in New Issue
Block a user