D3D_M4N
D3D_M4N

Reputation: 35

Is it possible to send TCP packet to a specific port with scapy's send function?

I am trying to send and receive an TCP packet with data on it. My current line of code for sending is:

send(IP(src="1.1.1.1",dst="1.2.3.4")/TCP()/"Test")

How would I specify a Port

Upvotes: 1

Views: 913

Answers (1)

myNameisShourya
myNameisShourya

Reputation: 44

I have an simple idea:

port = random.randint(48620, 49150)

If you want to know what is port, go to:

https://www.techtarget.com/searchnetworking/definition/port-number

Thanks

Upvotes: 1

Related Questions