Small fix

This commit is contained in:
lgandx 2021-12-07 17:59:54 -03:00
parent d425783be9
commit 6e2c77168f

View file

@ -339,8 +339,6 @@ def ConnectAndChoseSMB(host):
s.settimeout(Timeout)
try:
s.connect(host)
except:
return False
h = SMBHeader(cmd="\x72",flag1="\x00")
n = SMBNego(Data = SMB2NegoData())
n.calculate()
@ -348,6 +346,8 @@ def ConnectAndChoseSMB(host):
buffer0 = longueur(packet0)+packet0
s.send(NetworkSendBufferPython2or3(buffer0))
data = s.recv(4096)
except:
return False
if ParseNegotiateSMB2Ans(data):
try:
while True: