The condition is , Fax Modem is available over a TCP socket. Let say .. 192.168.1.59 port 4001 Now, in…