mirror of
https://github.com/lgandx/Responder.git
synced 2025-07-16 10:02:53 -07:00
FindSMB2UPTime now working properly
This commit is contained in:
parent
ee033e0c7f
commit
c9eca961cc
2 changed files with 42 additions and 4 deletions
8
tools/FindSMB2UPTime.py
Normal file → Executable file
8
tools/FindSMB2UPTime.py
Normal file → Executable file
|
@ -21,13 +21,13 @@ import struct
|
|||
import socket
|
||||
|
||||
sys.path.insert(0, os.path.realpath(os.path.join(os.path.dirname(__file__), '..')))
|
||||
from packets import SMBHeader, SMBNego, SMBNegoData
|
||||
from packets import SMBHeader,SMB2Header, SMB2Nego, SMB2NegoData
|
||||
|
||||
def GetBootTime(data):
|
||||
Filetime = int(struct.unpack('<q',data)[0])
|
||||
t = divmod(Filetime - 116444736000000000, 10000000)
|
||||
time = datetime.datetime.fromtimestamp(t[0])
|
||||
return time, time.strftime('%Y-%m-%d %Header:%M:%S')
|
||||
return time, time.strftime('%Y-%m-%d %H:%M:%S')
|
||||
|
||||
|
||||
def IsDCVuln(t):
|
||||
|
@ -47,8 +47,8 @@ def run(host):
|
|||
s.connect(host)
|
||||
s.settimeout(5)
|
||||
|
||||
Header = SMBHeader(Cmd="\x72",Flag1="\x18",Flag2="\x53\xc8")
|
||||
Nego = SMBNego(Data = SMBNegoData())
|
||||
Header = SMB2Header(Cmd="\x72",Flag1="\x18",Flag2="\x53\xc8")
|
||||
Nego = SMB2Nego(Data = SMB2NegoData())
|
||||
Nego.calculate()
|
||||
|
||||
Packet = str(Header)+str(Nego)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue