Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I create RAW TCP/IP packets in C++?

I'm a beginning C++ programmer / network admin, but I figure I can learn how to do this if someone points me in the right direction. Most of the tutorials are demonstrated using old code that no longer works for some reason.

Since I'm on Linux, all I need is an explanation on how to write raw Berkeley sockets. Can someone give me a quick run down?


1 Answers

Start by reading Beej's guide on socket programming . It will bring you up to speed on how to start writing network code. After that you should be able to pick up more and more information from reading the man pages.

Most of it will consist of reading the documentation for your favourite library, and a basic understanding of man pages.

like image 89
X-Istence Avatar answered Sep 14 '25 17:09

X-Istence