Sockets Vocabulary

Sockets have their own set of vocabulary, let’s have a look at them – 

Term Description
Domain The set of protocols used for transport mechanisms like AF_INET, PF_INET, etc.
Type Type of communication between sockets
Protocol Identifies the type of protocol used within domain and type. Typically it is zero
Port The server listens for clients calling on one or more ports. it can be a string containing a port number, a name of the service, or a Fixnum port
Hostname

Identifies a network interface. It can be a 

  • a string containing hostname, IPv6 address, or a double-quad address.
  • an integer
  • a zero-length string
  • a string “<broadcast>”

Python Network Programming

Python provides two levels of access to network programming. These are – 

  • Low-Level Access: At the low level, you can access the basic socket support of the operating system. You can implement client and server for both connection-oriented and connectionless protocols.
  • High-Level Access: At the high level allows to implement protocols like HTTP, FTP, etc.

In this article, we will discuss Network Socket Programming. But before getting started let’s understand what are sockets.

Similar Reads

What are Sockets?

Consider a bidirectional communication channel, the sockets are the endpoints of this communication channel. These sockets (endpoints) can communicate within a process, between processes on the same machine, or between processes on different machines. Sockets use different protocols for determining the connection type for port-to-port communication between clients and servers....

Sockets Vocabulary

Sockets have their own set of vocabulary, let’s have a look at them –...

Socket Programming

Socket programming is a way of connecting two nodes on a network to communicate with each other. One socket(node) listens on a particular port at an IP, while the other socket reaches out to the other to form a connection. The server forms the listener socket while the client reaches out to the server. They are the real backbones behind web browsing. In simpler terms, there is a server and a client. We can use the socket module for socket programming. For this, we have to include the socket module –...

Socket Server Methods

...

Socket Client Methods

These methods are used on the server-side. Let’s see each method in detail –...

Socket General Methods

This method is used on the client side. Let’s see this method in detail –...

Simple Server Client Program

These are the general methods of the socket module. Let’s see each method in detail....