listen(backlogstarts listening for incoming connections backlog specifies the maximum number of pending connections the operating system should queue before connections are refused the value should be at least with being sufficient for most applications makefile([mode [bufsize]]creates file object associated with the socket mode and bufsize have the same meaning as with the built-in open(function the file object uses duplicated version of the socket file descriptorcreated using os dup()so the file object and socket object can be closed or garbage-collected independently the socket should not have timeout and should not be configured in nonblocking mode recv(bufsize [flags]receives data from the socket the data is returned as string the maximum amount of data to be received is specified by bufsize flags provides additional information about the message and is usually omitted (in which case it defaults to zeroif usedit' usually set to one of the following constants (system-dependent)constant description msg_dontroute msg_dontwait msg_eor bypasses routing table lookup (sends onlynon-blocking operation indicates that the message is last in record usually only used when sending data on sock_seqpacket sockets looks at data but doesn' discard (receives onlyreceives/sends out-of-band data doesn' return until the requested number of bytes have been read (receives onlymsg_peek msg_oob msg_waitall recv_into(buffer [nbytes [flags]]the same as recv(except that data is written into an object buffer supporting the buffer interface nbytes is the maximum number of bytes to receive if omittedthe maximum size is taken from the buffer size flags has the same meaning as for recv( recvfrom(bufsize [flags]like the recv(method except that the return value is pair (dataaddressin which data is string containing the data received and address is the address of the socket sending the data the optional flags argument has the same meaning as for recv(this function is primarily used in conjunction with the udp protocol recvfrom_info(buffer [nbytes [flags]]the same as recvfrom(but the received data is stored in the buffer object buffer nbytes specifies the maximum number of bytes of receive if omittedthe maximum size is taken from the size of buffer flags has the same meaning as for recv( lib fl ff