Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. Network Email Sniffer in C#?

Network Email Sniffer in C#?

Scheduled Pinned Locked Moved C#
csharpsysadminbusinessquestion
2 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    Tom Paluzzi
    wrote on last edited by
    #1

    Hello... I'm in the process of writing a network analyzer in C# for an IT project. One of the project requirements is for the analyzer to report some metadata concerning Exchange-based emails that go out to the internet. Currently, I've got a simple listening socket (RAW socket) that is intercepting the network packets. The questions are: 1) Where in the IP packet (Ehternet, IP, or TCP header) can I inspect to determine that it's an Exchange-related packet and needs to be process (inspected) further. I'm pretty sure the IP packet would be of type TCP, but 2) Where in that series of bytes does it specify Exchange, the to:/from:/subject:/ etc. Is it the TCP header, IP?? 3) Is the a doable thing? I'm assuming that Exchange is using SMTP for sending the email(s). Any info would be extremely helpful... Thx, T

    L 1 Reply Last reply
    0
    • T Tom Paluzzi

      Hello... I'm in the process of writing a network analyzer in C# for an IT project. One of the project requirements is for the analyzer to report some metadata concerning Exchange-based emails that go out to the internet. Currently, I've got a simple listening socket (RAW socket) that is intercepting the network packets. The questions are: 1) Where in the IP packet (Ehternet, IP, or TCP header) can I inspect to determine that it's an Exchange-related packet and needs to be process (inspected) further. I'm pretty sure the IP packet would be of type TCP, but 2) Where in that series of bytes does it specify Exchange, the to:/from:/subject:/ etc. Is it the TCP header, IP?? 3) Is the a doable thing? I'm assuming that Exchange is using SMTP for sending the email(s). Any info would be extremely helpful... Thx, T

      L Offline
      L Offline
      LighthouseJ
      wrote on last edited by
      #2

      What if you used a program called Ethereal to capture the traffic you want to sniff. Figure out what trigger you are looking for and then program that into your project? Ethereal can get very detailed and can show you where the data is in the packets you are looking for. It parses out the data automatically based on what protocol it's sent and can show you the raw data if you need to see it.

      1 Reply Last reply
      0
      Reply
      • Reply as topic
      Log in to reply
      • Oldest to Newest
      • Newest to Oldest
      • Most Votes


      • Login

      • Don't have an account? Register

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • World
      • Users
      • Groups