CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7
  1. #1
    Join Date
    Sep 2015
    Posts
    4

    filter http packet by content

    Hi
    I want to write a program ( or use someone existed) that analyze http packets and filter that has my html sample.You know our request to a site return to us as a html and css and javascript form and I want to filter http packets that has my html code.
    performance is very important for me in this idea.
    tnx

  2. #2
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    4,626

    Re: filter http packet by content

    Wireshark ? Fiddler ?

  3. #3
    Join Date
    Sep 2015
    Posts
    4

    Re: filter http packet by content

    block than packets.

  4. #4
    Join Date
    Sep 2015
    Posts
    4

    Re: filter http packet by content

    Quote Originally Posted by addr3ss View Post
    block than packets.
    Edit: block that packets in linux.

  5. #5
    Join Date
    Mar 2001
    Posts
    2,529

    Re: filter http packet by content

    Blocking packets by content is done with the firewall on Linux.

    http://stackoverflow.com/questions/8...ing-in-payload

    Also I second OReubens, you want to either write or make a packet sniffer. Possibly you can use a 3rd party packet sniffer and use their API or Application Programming Interface.
    ahoodin
    To keep the plot moving, that's why.

  6. #6
    Join Date
    Sep 2015
    Posts
    4

    Re: filter http packet by content

    iptables not designed for this.what sniffer APIs are there?which one has better performance?

  7. #7
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    4,626

    Re: filter http packet by content

    You either want to look into hooking the api's the libraries from wireshark (libwireshark or it's lower level version libpcap) or fiddler (fiddlercore) provide. (easiest)

    or you want to use the Windows Filtering Platform. (user mode).

    or you want to look into a TDI driver or a Firewall hook driver (but then you'll need to write a kernel mode driver).

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured