Well next step in this project after I have got UDP alive is to receive and send raw packets too. My first impression was that this should be even simpler by just changing a couple of parameters in the socket but it just doesn't work. I have just taken my functional UDP code and modified a few lines. It executes with no errors until "sento" that always claims to have an invalid argument.
Am I missing something or are the raw packets not as simple as this in Linux? (In windows they are a pain and here I am using PWinCap)
Thanks,
Jens.
int sendRAW(void) { struct sockaddr_in si_other; int s, i, slen=sizeof(si_other); char buf[BUFLEN];
if ((s=socket(PF_PACKET, SOCK_DGRAM, htons((short)ETH_P_ALL)))==-1) diep("socket");
memset((char *) &si_other, sizeof(si_other), 0); si_other.sin_family = PF_PACKET;
for (i=0; i