[Mono-list] socket.raw as root

Ellis, Edward edward.ellis@pnl.gov
Fri, 18 Jun 2004 14:38:43 -0700


I am not sure if this applies in your case, but there are privileged
sockets (0-1023) and non-privileged sockets (1024-65536).  If this is
not your problem, then it may be an issue that raw sockets bypass the
standard protocols and can be used for nefarious purposes.  I am sure
about the first statement, the second is just a guess.

J. Edward Ellis

Pacific Northwest National Laboratory
(509) 375-3627 voice
(509) 375-2379 FAX
mailto:edward.ellis@pnl.gov=20



-----Original Message-----
From: mono-list-admin@lists.ximian.com
[mailto:mono-list-admin@lists.ximian.com] On Behalf Of Eric Gonia
Sent: Friday, June 18, 2004 9:30 AM
To: mono-list@lists.ximian.com
Subject: [Mono-list] socket.raw as root

Would someone please explain to me why I have to be root in order to
create a raw socket:

Socket socket =3D new Socket(AddressFamily.InterNetwork, SocketType.Raw,
ProtocolType.Icmp);

but I can create a Stream socket as a normal user:

Socket socket =3D new Socket(AddressFamily.InterNetwork,
SocketType.Stream, ProtocolType.Tcp);


And is there a way to get around the root privilege requirement for raw
sockets?

Thanks,
Eric