Winpcap programming 1 -- Introduction

Source: Internet
Author: User

Http://www.cnblogs.com/TianFang/archive/2007/11/26/972681.html

Winpcap programming 1 -- Introduction

What is Winpcap?

Winpcap is an open-source database based on Win32 platform for capturing and analyzing network data packets.

Most network applications access the network through widely used operating system components, such as sockets.
This is a simple implementation method, because the operating system has properly handled the underlying implementation details (such as protocol processing, encapsulation of data packets, and so on), and provides a class similar to reading and writing files, familiar interfaces.

However, in some cases, this "Simple Method" cannot meet the task requirements, because some applications need to directly access packets in the network. That is to say, those applications need to access the original data packets, that is, the data packets that have not been processed by the operating system using the network protocol.

The purpose of Winpcap is to provide this access method for Win32 applications. Winpcap provides the following functions:

  1. Capture the original data packet, whether it is sent to a machine or exchanged on other devices (shared media)
  2. Filters data packets based on user-specified rules before they are sent to an application.
  3. Send original data packets over the network
  4. Collect and collect Network Traffic Information

The above functions can be implemented only by using the network device driver installed in the Win32 kernel, coupled with several dynamic link library DLL.

All these functions can be presented through a powerful programming interface, which is easy to develop and can be used on different operating systems. The main goal of this manual is to describe the use of these programming interfaces with the help of some program examples.

WhatThe program is using Winpcap

Winpcap can be used to create network analysis and monitoring tools. Some typical applications based on Winpcap include:

  1. Network and Protocol analyzers)
  2. Network monitors)
  3. Network Traffic recorder (Traffic loggers)
  4. Network Traffic Generator (Traffic generators)
  5. User-level bridges and Routers)
  6. Network Intrusion Detection Systems (NIDS ))
  7. Network Scanners)
  8. Security Tools)

What does Winpcap do?

Winpcap capabilityIndependentSend and accept data through the host protocol, just like TCP/IP. This means that Winpcap cannot block, filter, or manipulate the communication of other applications on the same machine: it can simply "Monitor" packets transmitted over the network. Therefore, it cannot provide support such as network traffic control, service quality scheduling, and personal firewall.

What is Winpcap?

Winpcap is an open-source database based on Win32 platform for capturing and analyzing network data packets.

Most network applications access the network through widely used operating system components, such as sockets.
This is a simple implementation method, because the operating system has properly handled the underlying implementation details (such as protocol processing, encapsulation of data packets, and so on), and provides a class similar to reading and writing files, familiar interfaces.

However, in some cases, this "Simple Method" cannot meet the task requirements, because some applications need to directly access packets in the network. That is to say, those applications need to access the original data packets, that is, the data packets that have not been processed by the operating system using the network protocol.

The purpose of Winpcap is to provide this access method for Win32 applications. Winpcap provides the following functions:

  1. Capture the original data packet, whether it is sent to a machine or exchanged on other devices (shared media)
  2. Filters data packets based on user-specified rules before they are sent to an application.
  3. Send original data packets over the network
  4. Collect and collect Network Traffic Information

The above functions can be implemented only by using the network device driver installed in the Win32 kernel, coupled with several dynamic link library DLL.

All these functions can be presented through a powerful programming interface, which is easy to develop and can be used on different operating systems. The main goal of this manual is to describe the use of these programming interfaces with the help of some program examples.

WhatThe program is using Winpcap

Winpcap can be used to create network analysis and monitoring tools. Some typical applications based on Winpcap include:

  1. Network and Protocol analyzers)
  2. Network monitors)
  3. Network Traffic recorder (Traffic loggers)
  4. Network Traffic Generator (Traffic generators)
  5. User-level bridges and Routers)
  6. Network Intrusion Detection Systems (NIDS ))
  7. Network Scanners)
  8. Security Tools)

What does Winpcap do?

Winpcap capabilityIndependentSend and accept data through the host protocol, just like TCP/IP. This means that Winpcap cannot block, filter, or manipulate the communication of other applications on the same machine: it can simply "Monitor" packets transmitted over the network. Therefore, it cannot provide support such as network traffic control, service quality scheduling, and personal firewall.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.