[Tutor] How to write server which listens to specific port

Alan Gauld alan.gauld at btinternet.com
Tue Apr 14 09:58:33 CEST 2009

"ShivKumar Anand" <shiv_mbm at hotmail.com> wrote 

> My problem is I dont know how to send/receive a file using socket.
> How to get the filename specifically.

Could you use ftp? There is an ftp module.

You need to work out what you want to do over this connection 
and choose the appropriate protocol. Then you can use a higher 
level module if one is available.

Raw sockets should only be needed if you are doing bespoke 
communications between processes.

Alan Gauld
Author of the Learn to Program web site

More information about the Tutor mailing list