So today I bought the course from udemy:
Mastering Python – Networking and Security. The first lessons is about Python 2 vs 3, standard Python, console, running scripts, variables, loops, scoping, subroutines, system calls etc, a new refresh with code and videos.
Networking section 3:
22: Network byte order:
Endian describes how the order order in a multi-byte digital integer is arranged, more specifically whether they are read from right to left or left to right. The term is usually used in the two variants Big Endian and Little Endian.
The term originated originally from Jonathan Swift’s novel Gullivers travels from 1726. The novel described the tension in the country of Lilleput, where war broke out because of the controversies about which end of the egg they were going to cook.
23: Name server lookups
Two important functions from socket:
socket.gethostbyaddr(“22.214.171.124”), machines / devices uses this
socket.gethostbyname(“www.google.com”), humans can easily remember this for use.
The result of endian and the two functions:
24: Network client:
Next up is a network client that will send a byte array to local host on port 5555.
The client will fail if there is noting listening on that port, so we need to move on to the next step or use netcat (Netcat (often abbreviated to nc) is a computer networking utility for reading from and writing to network connections using TCP or UDP.)
24: Network server
The network server will listen port 5555, for both the server and client we will use TCP and internet as layer. We will also decode the byte array sent and print it as well as write it to storage.dat