├── 00_tutorials ├── 00_hello_socket.c ├── 01_create_a_socket.c ├── 02_resolve_hostname.c ├── 03_resolve_port_number.c ├── 04_connect_http_server.c ├── 05_send_first_http_request.c ├── 06_receive_http_response.c ├── 07_http_redirection.c ├── 08_simple_client_server.c ├── 09_multithread_client_server.c ├── 10_peer_to_peer_client_server.c ├── 11_non_blocking_sockets.c ├── 12_multiplexing_select_client_server.c ├── 13_multiplexing_poll_client_server.c ├── 14_broadcasting.c └── CMakeLists.txt ├── 01_networking_libraries ├── libcurl │ ├── CMakeLists.txt │ └── src │ │ ├── basic_curl.cpp │ │ ├── curl_multi_handle.cpp │ │ └── curl_multithreaded.cpp ├── my_http_server │ ├── CMakeLists.txt │ ├── README.md │ ├── defs.h │ ├── http_connection_handler.cpp │ ├── http_connection_handler.h │ ├── http_parser.cpp │ ├── http_parser.h │ ├── http_request.h │ ├── http_response.cpp │ ├── http_response.h │ ├── http_root │ │ ├── 200 │ │ │ └── index.html │ │ ├── 400 │ │ │ └── index.html │ │ ├── 403 │ │ │ └── index.html │ │ ├── 404 │ │ │ └── index.html │ │ ├── 500 │ │ │ └── index.html │ │ └── index.html │ ├── http_router.cpp │ ├── http_router.h │ ├── http_server.cpp │ ├── http_server.h │ ├── http_server_design.png │ ├── logging.h │ ├── main.cpp │ ├── utils.cpp │ └── utils.h └── openssl │ ├── CMakeLists.txt │ ├── certificate │ ├── make_cert.sh │ ├── server.crt │ ├── server.csr │ └── server.key │ └── src │ ├── https_client.c │ └── ssl_client_server.c ├── README.md ├── SSL_client_workflow.png ├── SSL_server_workflow.png ├── how_https_work.png ├── http_connection.png ├── tcp_based_client_server.png └── udp_based_client_server.png /00_tutorials/00_hello_socket.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/00_hello_socket.c -------------------------------------------------------------------------------- /00_tutorials/01_create_a_socket.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/01_create_a_socket.c -------------------------------------------------------------------------------- /00_tutorials/02_resolve_hostname.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/02_resolve_hostname.c -------------------------------------------------------------------------------- /00_tutorials/03_resolve_port_number.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/03_resolve_port_number.c -------------------------------------------------------------------------------- /00_tutorials/04_connect_http_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/04_connect_http_server.c -------------------------------------------------------------------------------- /00_tutorials/05_send_first_http_request.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/05_send_first_http_request.c -------------------------------------------------------------------------------- /00_tutorials/06_receive_http_response.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/06_receive_http_response.c -------------------------------------------------------------------------------- /00_tutorials/07_http_redirection.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/07_http_redirection.c -------------------------------------------------------------------------------- /00_tutorials/08_simple_client_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/08_simple_client_server.c -------------------------------------------------------------------------------- /00_tutorials/09_multithread_client_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/09_multithread_client_server.c -------------------------------------------------------------------------------- /00_tutorials/10_peer_to_peer_client_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/10_peer_to_peer_client_server.c -------------------------------------------------------------------------------- /00_tutorials/11_non_blocking_sockets.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/11_non_blocking_sockets.c -------------------------------------------------------------------------------- /00_tutorials/12_multiplexing_select_client_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/12_multiplexing_select_client_server.c -------------------------------------------------------------------------------- /00_tutorials/13_multiplexing_poll_client_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/13_multiplexing_poll_client_server.c -------------------------------------------------------------------------------- /00_tutorials/14_broadcasting.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/14_broadcasting.c -------------------------------------------------------------------------------- /00_tutorials/CMakeLists.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/00_tutorials/CMakeLists.txt -------------------------------------------------------------------------------- /01_networking_libraries/libcurl/CMakeLists.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/libcurl/CMakeLists.txt -------------------------------------------------------------------------------- /01_networking_libraries/libcurl/src/basic_curl.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/libcurl/src/basic_curl.cpp -------------------------------------------------------------------------------- /01_networking_libraries/libcurl/src/curl_multi_handle.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/libcurl/src/curl_multi_handle.cpp -------------------------------------------------------------------------------- /01_networking_libraries/libcurl/src/curl_multithreaded.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/libcurl/src/curl_multithreaded.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/CMakeLists.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/CMakeLists.txt -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/README.md -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/defs.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/defs.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_connection_handler.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_connection_handler.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_connection_handler.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_connection_handler.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_parser.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_parser.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_parser.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_parser.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_request.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_request.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_response.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_response.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_response.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_response.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_root/200/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_root/200/index.html -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_root/400/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_root/400/index.html -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_root/403/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_root/403/index.html -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_root/404/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_root/404/index.html -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_root/500/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_root/500/index.html -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_root/index.html: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_root/index.html -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_router.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_router.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_router.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_router.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_server.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_server.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_server.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_server.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/http_server_design.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/http_server_design.png -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/logging.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/logging.h -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/main.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/main.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/utils.cpp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/utils.cpp -------------------------------------------------------------------------------- /01_networking_libraries/my_http_server/utils.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/my_http_server/utils.h -------------------------------------------------------------------------------- /01_networking_libraries/openssl/CMakeLists.txt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/CMakeLists.txt -------------------------------------------------------------------------------- /01_networking_libraries/openssl/certificate/make_cert.sh: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/certificate/make_cert.sh -------------------------------------------------------------------------------- /01_networking_libraries/openssl/certificate/server.crt: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/certificate/server.crt -------------------------------------------------------------------------------- /01_networking_libraries/openssl/certificate/server.csr: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/certificate/server.csr -------------------------------------------------------------------------------- /01_networking_libraries/openssl/certificate/server.key: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/certificate/server.key -------------------------------------------------------------------------------- /01_networking_libraries/openssl/src/https_client.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/src/https_client.c -------------------------------------------------------------------------------- /01_networking_libraries/openssl/src/ssl_client_server.c: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/01_networking_libraries/openssl/src/ssl_client_server.c -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/README.md -------------------------------------------------------------------------------- /SSL_client_workflow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/SSL_client_workflow.png -------------------------------------------------------------------------------- /SSL_server_workflow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/SSL_server_workflow.png -------------------------------------------------------------------------------- /how_https_work.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/how_https_work.png -------------------------------------------------------------------------------- /http_connection.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/http_connection.png -------------------------------------------------------------------------------- /tcp_based_client_server.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/tcp_based_client_server.png -------------------------------------------------------------------------------- /udp_based_client_server.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/nguyenchiemminhvu/LinuxNetworkProgramming/HEAD/udp_based_client_server.png --------------------------------------------------------------------------------