diff options
author | Lennart Poettering <lennart@poettering.net> | 2003-08-10 19:56:53 +0000 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2003-08-10 19:56:53 +0000 |
commit | dac9fede8c1064797eee70cca6946d05b7a929f9 (patch) | |
tree | b119b186c7351ce39e336539678351b299304949 /src | |
parent | 3e81b0123b4bbfedbdc1135a6a4305c347f91a3a (diff) |
Great cleanup
Ready for first release
git-svn-id: file:///home/lennart/svn/public/aeswepd/trunk@4 022f378f-78c4-0310-b860-d162c87e6274
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.am | 51 | ||||
-rw-r--r-- | src/aes.c | 20 | ||||
-rw-r--r-- | src/aes.h | 20 | ||||
-rw-r--r-- | src/aeswepd.c | 32 | ||||
-rw-r--r-- | src/aeswepd.h | 27 | ||||
-rw-r--r-- | src/assocwatch.c | 20 | ||||
-rw-r--r-- | src/assocwatch.h | 20 | ||||
-rw-r--r-- | src/exec.c | 20 | ||||
-rw-r--r-- | src/exec.h | 20 | ||||
-rw-r--r-- | src/ifmonitor.c | 20 | ||||
-rw-r--r-- | src/ifmonitor.h | 20 | ||||
-rw-r--r-- | src/interface.c | 21 | ||||
-rw-r--r-- | src/interface.h | 22 | ||||
-rw-r--r-- | src/iwapi.c | 20 | ||||
-rw-r--r-- | src/iwapi.h | 20 | ||||
-rw-r--r-- | src/iwkey.c | 20 | ||||
-rw-r--r-- | src/iwkey.h | 20 | ||||
-rw-r--r-- | src/nlapi.c | 20 | ||||
-rw-r--r-- | src/nlapi.h | 20 | ||||
-rw-r--r-- | src/util.c | 20 | ||||
-rw-r--r-- | src/util.h | 21 | ||||
-rw-r--r-- | src/waproamd.c | 33 | ||||
-rw-r--r-- | src/waproamd.h | 36 | ||||
-rw-r--r-- | src/wireless.h | 27 |
24 files changed, 543 insertions, 27 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index a55c459..1080a15 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,6 +1,51 @@ +# $Id$ + +# This file is part of waproamd. +# +# waproamd is free software; you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 2 of the License, or +# (at your option) any later version. +# +# waproamd is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with waproamd; if not, write to the Free Software Foundation, +# Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + AM_CFLAGS = -DSYSCONFDIR="\"$(sysconfdir)\"" -sbin_PROGRAMS = waproamd aeswepd +sbin_PROGRAMS = + +if BUILD_WAPROAMD +sbin_PROGRAMS += waproamd + +waproamd_SOURCES = waproamd.c waproamd.h \ + interface.c interface.h \ + iwapi.c iwapi.h \ + util.c util.h \ + exec.c exec.h \ + nlapi.c nlapi.h \ + assocwatch.c assocwatch.h \ + ifmonitor.c ifmonitor.h \ + wireless.h wireless.15.h +endif + +if BUILD_AESWEPD +sbin_PROGRAMS += aeswepd + +aeswepd_SOURCES = aeswepd.c aeswepd.h \ + aes.c aes.h \ + interface.c interface.h \ + iwkey.c iwkey.h \ + util.c util.h \ + wireless.h wireless.15.h + +aeswepd_LDADD = -lmcrypt -aeswepd_SOURCES = aeswepd.c aeswepd.h aes.c aes.h interface.c interface.h iwkey.c iwkey.h util.c util.h -waproamd_SOURCES = waproamd.c interface.c interface.h iwapi.c iwapi.h util.c util.h exec.c exec.h nlapi.c nlapi.h assocwatch.c assocwatch.h ifmonitor.c ifmonitor.h +install-exec-hook: + cd $(DESTDIR)/$(sbindir) && ln -sf aeswepd aeswepls +endif @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <mcrypt.h> #include <stdio.h> #include <string.h> @@ -1,6 +1,26 @@ #ifndef fooaeshfoo #define fooaeshfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdint.h> int aes_crypt(uint8_t *key, uint8_t *data, uint8_t *result); diff --git a/src/aeswepd.c b/src/aeswepd.c index 9b4c07f..684b224 100644 --- a/src/aeswepd.c +++ b/src/aeswepd.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #define _GNU_SOURCE #include <assert.h> @@ -24,14 +44,6 @@ #include "interface.h" #include "util.h" -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif - -#ifndef VARLIBAESWEPD -#define VARLIBAESWEPD "/var/lib/aeswepd" -#endif - uint8_t aes_key[AES_KEY_LEN]; int rekey_time = 15*60; int n_max_keys = 3; @@ -55,7 +67,7 @@ const char *get_status_file_name(void) { } -int do_list_keys() { +int do_list_keys(void) { FILE *f; char ln[256]; @@ -338,7 +350,7 @@ void parse_args(int argc, char *argv[]) { b = argv[0]; - if (strcmp(b, "aeswepl") == 0) + if (strcmp(b, "aeswepls") == 0) _list_keys = 1; memset(aes_key, sizeof(aes_key), 0); diff --git a/src/aeswepd.h b/src/aeswepd.h index c3be819..0313ed6 100644 --- a/src/aeswepd.h +++ b/src/aeswepd.h @@ -1,6 +1,26 @@ #ifndef fooaeswepdhfoo #define fooaeswepdhfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdint.h> #define WEP_KEY_LEN 13 @@ -10,5 +30,12 @@ extern int n_max_keys; extern int key_map[MAX_WEP_KEYS]; +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#ifndef VARLIBAESWEPD +#define VARLIBAESWEPD "/var/lib/aeswepd" +#endif #endif diff --git a/src/assocwatch.c b/src/assocwatch.c index c3bf5f2..a2191bd 100644 --- a/src/assocwatch.c +++ b/src/assocwatch.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <sys/types.h> #include <sys/socket.h> #include <linux/types.h> diff --git a/src/assocwatch.h b/src/assocwatch.h index 7a06f87..77fd732 100644 --- a/src/assocwatch.h +++ b/src/assocwatch.h @@ -1,6 +1,26 @@ #ifndef fooassocwatchfoo #define fooassocwatchfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include "util.h" int assocwatch_init(int (*cb) (int idx, struct hw_addr *a)); @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <sys/types.h> #include <unistd.h> #include <string.h> @@ -1,6 +1,26 @@ #ifndef fooexehfoo #define fooexehfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + int log_exec(const char *dir, const char *prog, const char *arg); #endif diff --git a/src/ifmonitor.c b/src/ifmonitor.c index b1124a5..c1e05ec 100644 --- a/src/ifmonitor.c +++ b/src/ifmonitor.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdio.h> #include <sys/socket.h> #include <linux/types.h> diff --git a/src/ifmonitor.h b/src/ifmonitor.h index cdbb5dd..f860dc2 100644 --- a/src/ifmonitor.h +++ b/src/ifmonitor.h @@ -1,6 +1,26 @@ #ifndef fooifmonitorhfoo #define fooifmonitorhfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + int ifmonitor_init(int (*cb) (int b, int index, unsigned short type, const char *name)); #endif diff --git a/src/interface.c b/src/interface.c index 5fa7dfb..72030c3 100644 --- a/src/interface.c +++ b/src/interface.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdio.h> #include <errno.h> #include <string.h> @@ -8,6 +28,7 @@ #include "interface.h" #include "util.h" +#include "wireless.h" struct interface *interface_open(char *name) { struct interface* i = NULL; diff --git a/src/interface.h b/src/interface.h index b6f3b9d..c05c5b3 100644 --- a/src/interface.h +++ b/src/interface.h @@ -1,8 +1,28 @@ #ifndef foointerfacehfoo #define foointerfacehfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <sys/socket.h> -#include "wireless.h" +#include <linux/if.h> #include "util.h" struct interface { diff --git a/src/iwapi.c b/src/iwapi.c index 5662548..e9b4177 100644 --- a/src/iwapi.c +++ b/src/iwapi.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <net/if_arp.h> #include <errno.h> #include <assert.h> diff --git a/src/iwapi.h b/src/iwapi.h index bf65829..9a15387 100644 --- a/src/iwapi.h +++ b/src/iwapi.h @@ -1,6 +1,26 @@ #ifndef fooiwapihfoo #define fooiwapihfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include "interface.h" #include "wireless.h" #include "util.h" diff --git a/src/iwkey.c b/src/iwkey.c index 3875594..b4b44c5 100644 --- a/src/iwkey.c +++ b/src/iwkey.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <assert.h> #include <string.h> #include <stdio.h> diff --git a/src/iwkey.h b/src/iwkey.h index 8e412d4..3b39f7e 100644 --- a/src/iwkey.h +++ b/src/iwkey.h @@ -1,6 +1,26 @@ #ifndef fooiwkeyhfoo #define fooiwkeyhfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdint.h> #include "interface.h" #include "aeswepd.h" diff --git a/src/nlapi.c b/src/nlapi.c index 1f6e690..d88a1ed 100644 --- a/src/nlapi.c +++ b/src/nlapi.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdio.h> #include <string.h> #include <unistd.h> diff --git a/src/nlapi.h b/src/nlapi.h index 11ee81d..e7e369f 100644 --- a/src/nlapi.h +++ b/src/nlapi.h @@ -1,6 +1,26 @@ #ifndef foonlapihfoo #define foonlapihfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdint.h> #include <sys/socket.h> #include <linux/types.h> @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <unistd.h> #include <sys/socket.h> #include <string.h> @@ -1,6 +1,26 @@ #ifndef fooutilhfoo #define fooutilhfoo +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #include <stdio.h> #include <stdint.h> @@ -16,7 +36,6 @@ struct hw_addr { uint8_t addr[ETH_ALEN]; }; - extern struct hw_addr null_ap; void print_hex(FILE *f, uint8_t *w, int l); diff --git a/src/waproamd.c b/src/waproamd.c index c2af3af..430c839 100644 --- a/src/waproamd.c +++ b/src/waproamd.c @@ -1,3 +1,23 @@ +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + #define _GNU_SOURCE #include <assert.h> @@ -20,18 +40,7 @@ #include "nlapi.h" #include "ifmonitor.h" #include "assocwatch.h" - -#ifndef SYSCONFDIR -#define SYSCONFDIR "/etc/waproamd" -#endif - -#ifndef SCRIPTDIR -#define SCRIPTDIR SYSCONFDIR"/scripts" -#endif - -#ifdef HAVE_CONFIG_H -#include <config.h> -#endif +#include "waproamd.h" char *interface_name = NULL; int interface_index = -1; diff --git a/src/waproamd.h b/src/waproamd.h new file mode 100644 index 0000000..a6faefb --- /dev/null +++ b/src/waproamd.h @@ -0,0 +1,36 @@ +#ifndef foowaproamdhfoo +#define foowaproamdhfoo + +/* $Id$ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + +#ifndef SYSCONFDIR +#define SYSCONFDIR "/etc" +#endif + +#ifndef SCRIPTDIR +#define SCRIPTDIR SYSCONFDIR"/waproamd/scripts" +#endif + +#ifdef HAVE_CONFIG_H +#include <config.h> +#endif + +#endif diff --git a/src/wireless.h b/src/wireless.h new file mode 100644 index 0000000..db302a8 --- /dev/null +++ b/src/wireless.h @@ -0,0 +1,27 @@ +#ifndef foowirelesshfoo +#define foowirelesshfoo + +/* $Id: waproamd.c 1.12 Sat, 01 Feb 2003 03:00:07 +0100 lennart $ */ + +/* + * This file is part of waproamd. + * + * waproamd is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * waproamd is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with waproamd; if not, write to the Free Software Foundation, + * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. + */ + +#include <linux/if.h> +#include "wireless.15.h" + +#endif |