Question: We write the following program to send a packet. data = bHello, Server udp = socket.socket(socket.AF_INET, socket.SOCK_DGRAM) udp.sendto(data, (10.9.0.5, 9090)) (1) How is the source
We write the following program to send a packet.
data = b"Hello, Server"
udp = socket.socket(socket.AF_INET, socket.SOCK_DGRAM)
udp.sendto(data, ("10.9.0.5", 9090))
(1) How is the source port number of the packet decided?
(2) How is the source IP of the packet decided?
Step by Step Solution
There are 3 Steps involved in it
When you send data over a network using sockets especially in the context of the User Datagram Protocol UDP there are certain details regarding how th... View full answer
Get step-by-step solutions from verified subject matter experts
