Im trying to send get request to a certain website and save the source code that the server replay to me but after im doing the tree way handshake the connection is restarted
this is my code thanks for everyone...:
def Make_GET(URL):
Dns_File.seek(16)
ans = Find_IP(URL)
if(ans == 1):
print "You entered something different then Domain"
elif ans == -1:
print "Not found"
else:
print "The ip of the wanted domain is: "+ ans
ip_send=ans
SYN = IP(dst=ip_send) / TCP(dport=80,sport=1025, flags='S',seq=1000)
SYN_ACK = sr1(SYN)
SYN_ACK.show()
print "check 1"
print SYN_ACK[TCP].ack+1, SYN_ACK[TCP].seq + 1
get_packet=sr1(IP(dst=ip_send)/TCP(dport=80, sport=1025,
seq=SYN_ACK[TCP].ack+1, ack=SYN_ACK[TCP].seq + 1, flags='A'))
get_packet.show()
print "check 2"
this is what i see when im sniffing the packets in wire shark:click here