Get the App
SLTechnology News&Howtos  ›  Network Security  › 

Simple Network programming configuration based on WinPcap

Shulou Source: shulou.com Published: 2022-06-01 02:45:58 10月04日 Update

I. purpose of the experiment

1. Learn and master the basic methods of programming based on WinPcap.

2. By monitoring IP packet flow, we can understand the working principle of IP protocol and the basic structure of IP packet.

2. The content of the experiment is to write a console program using WinPcap to monitor IP packet traffic, which requires:

① runs as a command line: MonitorTraffic time, where MonitorTraffic is the program name

Third, the experimental steps and results

1) use the reference code to write a console program in the VS2010 development tool program.

2) add...\ WpdPack\ Include

Project-- > * * attribute (alt+F7)

Configure properties-- > inventory tool-- > input and output-- > embed list-- > No

Project-- > * * attribute (alt+F7)

Configuration Properties-- > Cramp Cure colors-- > General-- > additional inclusion directories-- >

Project-- > * * attribute (alt+F7)

Configuration Properties-- > Linker-- > General-- > additional Library Directory-- >

Project-- > * * attribute (alt+F7)

Configure properties-- > linker-- > input-- > attach dependencies-- > supplement "; Packet.lib;wpcap.lib"

Project-- > * * attribute (alt+F7)

Configuration properties-- > Candlestick colors-- > preprocessor-- > preprocessor definition-- > supplement "; HAVE_REMOTE"

IV. Code writing

5. Testing

Tags: Properties configurations projects labs programs attachments codes tools general console data traffic lists directories links controls monitoring input preprocessing programming Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Docker Linux Shulou Technology Apple Microsoft