1. TCP: Transmission Control Protocol IP used to detect errors in network transmissions: responsible for interconnection of different networks
2. TCP/IP protocol family: HTTP: (Hypetext Transfer Protocol) ARP (Address Resolution Protocol) Ip->mac Dos attack related to this
3. TCP/IP: Flow oriented, sticky packet phenomenon. UDP: Package-oriented, non-sticky package.
4. Socket:1) abstract descriptor for network communication 2) Auto Header (OS Help)
5. Socket is for NIC.
6. INET_ADDR () Converts a dotted decimal string into a network byte-order binary. Inet_ntoa () Dot decimal in network byte binary
7. SSH (Secure Shell Protocol) port number: DNS (domain Name System) port number: HTTP (Hypertext Transfer Protocol) port number: 80
8. Network transmission data must be network byte order (big endian byte order)
Host byte order--Network byte order htons network byte sequence, host byte order Ntohs
9. The macro definition is only valid for the first row.
10. The server must be bridged: Bind the NIC.
11. Network communication must have a return value.
12. The active end ID (client) can bind or bind. The operating system automatically binds any NIC.
The return value of accept is the socket FD of the client received.
14. Define the struct sockaddr_in variable and need to be emptied.
inet addr:127.0.0.1 Loopback ID (not native)
Network programming four-layer model