Path: utzoo!censor!geac!alias!mark From: mark@alias.UUCP (Mark Andrews) Newsgroups: comp.sys.sgi Subject: Use of snoop(7P) Message-ID: <739@alias.UUCP> Date: 7 Feb 90 15:04:29 GMT Distribution: na Organization: Alias Research Inc., Toronto, ON Canada Lines: 67 I have been playing with the snoop(7P) protocol on a variety of 4D's (4D/60,70, 20, 25) running Irix 3.2. My program was constructed using the examples in the manual page: #include #include #include #define ETHERHDRPAD RAW_HDRPAD(sizeof(struct ether_header)) struct etherpacket { struct snoopheader snoop; char pad[ETHERHDRPAD]; struct ether_header ether; char data[ETHERMTU]; }; main() { int s; struct sockaddr_raw sr; struct snoopfilter sf; struct etherpacket ep; int cc, on = 1; s = socket(AF_RAW, SOCK_RAW, RAWPROTO_SNOOP); bzero(sr.sr_ifname, RAW_IFNAMSIZ); /* * If the family is not set (not specified in manual page), bind * fails due to unsupported address family. */ sr.sr_family = AF_RAW; sr.sr_port = 0; if (bind(s, &sr, sizeof sr) < 0) { /* Error */ } bzero((char *) &sf, sizeof sf); if (ioctl(s, SIOCADDSNOOP, (struct snoopfilter *)&sf) < 0) { perror("Adding snoop filter"); exit(1); } < .... > ----------------------------------------------------------------------------- When the program attempts to add the snoopfilter to the socket, the ioctl() fails with the error ``Invalid argument'' and the following message appears on the console of the machine (4D/80S in this case): enp0: promisc. mode failed: no firmware support Is this going to be fixed on a future release ? I was hoping to use some of the above code to port tcpdump to Irix. ------------------------------------------------------------------------------ Mark Andrews Systems Programmer, Alias Research, Toronto, Canada Phone: (416)-362-9181 UUCP: mark%alias@csri.utoronto.ca