Raw ethernet?

Raw ethernet?

Post by Gene Mang » Tue, 30 Aug 1994 07:04:00



Hi all,

I need to write a program on Linux which gets all non-IP traffic from
the ethernet adapter - in promiscuous mode.   Can anyone point me to
some docs or simple examples of:

  - how to read raw ethernet frames (all or just non-IP)
  - how to send non-IP eth (I know how to build them, just not how
    to get them on the wire)
  - how to get the ethernet card into and out of promiscuous mode

I have several Unix programming books, including Stevens' Unix book
and Network programming book, but if it's in there, I can't find it...

Any help would be greatly appreciated.

+=================================+=========================================+  
| Gene Mangum                     |  OS/2 ver 2 - Increased productivity    |
| Univ of Michigan Hospitals      |               through the use of a      |

+=================================+=========================================+

 
 
 

Raw ethernet?

Post by Philip Shearer » Wed, 31 Aug 1994 23:32:09


: Hi all,
:  
: I need to write a program on Linux which gets all non-IP traffic from
: the ethernet adapter - in promiscuous mode.   Can anyone point me to
: some docs or simple examples of:
:  
Examples (but perhapse not simple) can be found by ftp(ing) to
gatekeeper.dec.com
password ftp

/pub/BSD/FreeBSD/FreeBSD-current/src/contrib/tcpdump/tcpdump
  DESCRIPTION

   tcpdump prints out the headers of packets on a network interface
   that match the boolean expression.
   Under SunOS:
     You must be root to invoke tcpdump or it must be installed
     setuid to root.
   Under Ultrix:
     Any user can invoke tcpdump once the super-user has enabled
     promiscuous-mode operation using pfconfig(8).
   Under BSD:
     Access is controlled by the permissions on /dev/bpf0 etc.

/pub/usenet/comp.sources.misc/volume42/etherload

   Included is a shar file for 'etherload'- to monitor the load
   on an ethernet from Unix systems.
   IRIX40          Silicon Graphics IRIX 4.0
   IRIX51          Silicon Graphics IRIX 5.1
   SUNOS4          Sun Microsystems SunOS 4.x
   SUNOS5          Sun Microsystems SunOS 5.x (Solaris 2.x)
   SVR4            AT&T System V Release 4
   ULTRIX          Digital Equipment Ultrix 4.x
   DECOSF          Digital Equipment OSF/1 V1.3 and later
   BSDI            BSDI/386

/pub/usenet/comp.sources.unix/volume20/etherlib

  This ethernet access library is a part of the Columbia Netmate project
  which is being released as a useful component in its own right.

  These functions provide access to the raw ethernet for user-level
  programs.  On Suns, they are implemented using NIT(4p) (network interface
  tap).  While they do not provide the full functionality of NIT, these
  functions do run on both the socket- and streams-based NIT
  implementations.  On Ultrix systems, they are implemented using DLI (data
  link interface).  On Berkeley systems, they are implemented using the
  Stanford enetfilter available as user-contributed software in the 4.3 BSD
  release.

Regards Philip

 
 
 

Raw ethernet?

Post by Lewis Per » Wed, 31 Aug 1994 20:39:27


Designing a system with serious demands for interprocess coordination, and
wanting to code it in such a way that it will be portable among (present or
future;-) Unixes, I apparently should look into POSIX 1003.1b (formerly
1003.4.)  The friendly folks at the IEEE are willing to send 51 ounces of
1003.1b for $95, but I wonder if this would be a good idea.  It's not just the
money - I'd pay $95 for Stevens's _Advanced Programming in the Unix
Environment_ if need be - but is this really the best way for a programmer to
grapple with the POSIX real-time standard?  If not, please, how else?

 |   |_  \    / : Lew Perin
 |__ |__  \/\/  : Home: (201)435-2679
 
 
 

Raw ethernet?

Post by W. Richard Steve » Thu, 01 Sep 1994 04:29:56


Quote:> Designing a system with serious demands for interprocess coordination, and
> wanting to code it in such a way that it will be portable among (present or
> future;-) Unixes, I apparently should look into POSIX 1003.1b (formerly
> 1003.4.)  The friendly folks at the IEEE are willing to send 51 ounces of
> 1003.1b for $95, but I wonder if this would be a good idea.  It's not just
> the money - I'd pay $95 for Stevens's _Advanced Programming in the Unix
> Environment_ if need be - but is this really the best way for a programmer to
> grapple with the POSIX real-time standard?  If not, please, how else?

Unfortunately, at this time the Posix standard is it.  The Solaris man
pages are available (/usr/share/man/man3r).

Also be aware that the IEEE has been selling this "vapor standard" for
about 4 months now, and it's still not available.  I've had my copy
backordered for 2 months and have yet to see it ...  And all (most?)
of the functions have been in Solaris 2.3 for almost a year.

        Rich Stevens

 
 
 

1. Need a raw ethernet interface

I'm trying to write an ethernet driver and it appears as though standard
Sun tools like etherfind won't show packets with errors.  So does anyone
know of a package, or tool that will work like etherfind only display errored
packets as well as 'good' ones?  By errors I mean all levels of errors, from
CRC to UDP protocol errors.  I have access to a Sun ELC I can configure to
do this, I could also plug a PC into that wire if I wanted to.

What I really need is a sniffer but my boss won't spring for one....

Thanks.

jim

--
So many women, so little charisma.
--------------------------------------------------------------
Jim Harkins                         [ucsd|uunet]!pacdata!jim

--------------------------------------------------------------

2. PCMCIA Driver Loading

3. sample code that sends raw Ethernet packets?

4. Wind95/DOS and Linux options

5. Raw Ethernet access

6. 4DWm for Linux.

7. Raw Ethernet packets in BSD

8. Secure Apache server

9. Send/receive raw ethernet frames

10. Need help! Raw ethernet socket question

11. Raw ethernet help

12. Raw ethernet socket

13. raw ethernet comms programming