1 --- ./arpd.c.orig Tue Aug 21 13:26:27 2001
2 +++ ./arpd.c Fri Aug 24 12:28:12 2001
4 #include <sys/socket.h>
5 #include <netinet/in.h>
10 static void arpd_print(char*, struct arpd_request*);
12 #define arpd_print(x,y)
15 -/* these shouldn't change for ipv4 */
16 +/* these shouldn't change for ipv4 */
17 #define ARPD_TRIEWIDTH 256
18 #define ARPD_TRIEDEPTH 8
22 +"ARP daemon - version 1.0.2 - PLD modified
24 +-u user, which you want to run this deamon
26 +The user you will take must have RW access to /dev/arpd.
27 +If you don't know what to choice take root.
32 + fprintf(stdout,usage);
37 union arpd_triedef * hash;
39 struct arpd_request req;
40 struct arpd_request *rep;
43 + unsigned int uid_num = 0;
48 + fprintf(stdout,"Invalid option.\n");
56 + if (strcasecmp(cmd, "-u") == 0) {
58 + pw=getpwnam(account);
60 + fprintf(stderr,"Unknown account.\n");
66 + fprintf(stderr,"Invalid option.\n");
82 openlog ("arpd", LOG_PID | LOG_CONS, LOG_DAEMON);
84 - syslog(LOG_NOTICE, "Initializing, version %s\n", ARPD_VERSION);
85 + syslog(LOG_NOTICE, "Initializing, modified version %s\n", ARPD_VERSION);
87 fd = open("/dev/arpd", O_RDWR);
89 + /* Set proper UID */
93 syslog(LOG_CRIT, "cannot open /dev/arpd: %m");
102 static void arpd_update (struct arpd_request * entry)