[T106][ZXW-22]7520V3SCV2.01.01.02P42U09_VEC_V0.8_AP_VEC origin source commit
Change-Id: Ic6e05d89ecd62fc34f82b23dcf306c93764aec4b
diff --git a/ap/lib/libnl/libnl-3.2.25/python/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/Makefile.am
new file mode 100644
index 0000000..a1a3426
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/Makefile.am
@@ -0,0 +1,3 @@
+# -*- Makefile -*-
+
+SUBDIRS = doc examples netlink tests
diff --git a/ap/lib/libnl/libnl-3.2.25/python/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/Makefile.in
new file mode 100644
index 0000000..696f623
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/Makefile.in
@@ -0,0 +1,623 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \
+ $(srcdir)/setup.py.in README
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES = setup.py
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+ ctags-recursive dvi-recursive html-recursive info-recursive \
+ install-data-recursive install-dvi-recursive \
+ install-exec-recursive install-html-recursive \
+ install-info-recursive install-pdf-recursive \
+ install-ps-recursive install-recursive installcheck-recursive \
+ installdirs-recursive pdf-recursive ps-recursive \
+ tags-recursive uninstall-recursive
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
+ distclean-recursive maintainer-clean-recursive
+am__recursive_targets = \
+ $(RECURSIVE_TARGETS) \
+ $(RECURSIVE_CLEAN_TARGETS) \
+ $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
+ distdir
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates. Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+ BEGIN { nonempty = 0; } \
+ { items[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique. This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+ list='$(am__tagged_files)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | $(am__uniquify_input)`
+ETAGS = etags
+CTAGS = ctags
+DIST_SUBDIRS = $(SUBDIRS)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+ dir0=`pwd`; \
+ sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+ sed_rest='s,^[^/]*/*,,'; \
+ sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+ sed_butlast='s,/*[^/]*$$,,'; \
+ while test -n "$$dir1"; do \
+ first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+ if test "$$first" != "."; then \
+ if test "$$first" = ".."; then \
+ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+ else \
+ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+ if test "$$first2" = "$$first"; then \
+ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+ else \
+ dir2="../$$dir2"; \
+ fi; \
+ dir0="$$dir0"/"$$first"; \
+ fi; \
+ fi; \
+ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+ done; \
+ reldir="$$dir2"
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+SUBDIRS = doc examples netlink tests
+all: all-recursive
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+setup.py: $(top_builddir)/config.status $(srcdir)/setup.py.in
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run 'make' without going through this Makefile.
+# To change the values of 'make' variables: instead of editing Makefiles,
+# (1) if the variable is set in 'config.status', edit 'config.status'
+# (which will cause the Makefiles to be regenerated when you run 'make');
+# (2) otherwise, pass the desired values on the 'make' command line.
+$(am__recursive_targets):
+ @fail=; \
+ if $(am__make_keepgoing); then \
+ failcom='fail=yes'; \
+ else \
+ failcom='exit 1'; \
+ fi; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+ID: $(am__tagged_files)
+ $(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+ set x; \
+ here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test ! -f $$subdir/TAGS || \
+ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
+ $(am__define_uniq_tagged_files); \
+ shift; \
+ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ if test $$# -gt 0; then \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ "$$@" $$unique; \
+ else \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$unique; \
+ fi; \
+ fi
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+ $(am__define_uniq_tagged_files); \
+ test -z "$(CTAGS_ARGS)$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && $(am__cd) $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive
+
+cscopelist-am: $(am__tagged_files)
+ list='$(am__tagged_files)'; \
+ case "$(srcdir)" in \
+ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+ *) sdir=$(subdir)/$(srcdir) ;; \
+ esac; \
+ for i in $$list; do \
+ if test -f "$$i"; then \
+ echo "$(subdir)/$$i"; \
+ else \
+ echo "$$sdir/$$i"; \
+ fi; \
+ done >> $(top_builddir)/cscope.files
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+ @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ $(am__make_dryrun) \
+ || test -d "$(distdir)/$$subdir" \
+ || $(MKDIR_P) "$(distdir)/$$subdir" \
+ || exit 1; \
+ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+ $(am__relativize); \
+ new_distdir=$$reldir; \
+ dir1=$$subdir; dir2="$(top_distdir)"; \
+ $(am__relativize); \
+ new_top_distdir=$$reldir; \
+ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+ ($(am__cd) $$subdir && \
+ $(MAKE) $(AM_MAKEFLAGS) \
+ top_distdir="$$new_top_distdir" \
+ distdir="$$new_distdir" \
+ am__remove_distdir=: \
+ am__skip_length_check=: \
+ am__skip_mode_fix=: \
+ distdir) \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-recursive
+all-am: Makefile
+installdirs: installdirs-recursive
+installdirs-am:
+install: install-recursive
+install-exec: install-exec-recursive
+install-data: install-data-recursive
+uninstall: uninstall-recursive
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-recursive
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-recursive
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-recursive
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic distclean-tags
+
+dvi: dvi-recursive
+
+dvi-am:
+
+html: html-recursive
+
+html-am:
+
+info: info-recursive
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-recursive
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-recursive
+
+install-html-am:
+
+install-info: install-info-recursive
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-recursive
+
+install-pdf-am:
+
+install-ps: install-ps-recursive
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-recursive
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-recursive
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-recursive
+
+pdf-am:
+
+ps: ps-recursive
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: $(am__recursive_targets) install-am install-strip
+
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
+ check-am clean clean-generic clean-libtool cscopelist-am ctags \
+ ctags-am distclean distclean-generic distclean-libtool \
+ distclean-tags distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ installdirs-am maintainer-clean maintainer-clean-generic \
+ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
+ ps ps-am tags tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/README b/ap/lib/libnl/libnl-3.2.25/python/README
new file mode 100644
index 0000000..4ccc337
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/README
@@ -0,0 +1,12 @@
+
+***************************************************************************
+
+NOTE: The python wrapper is experimental and may or may not work.
+
+***************************************************************************
+
+For the brave:
+
+ (requires an installed libnl)
+ - $ python ./setup.py build
+ - $ sudo python ./setup.py install
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/doc/Makefile.am
new file mode 100644
index 0000000..a2fe6f2
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/Makefile.am
@@ -0,0 +1,8 @@
+# -*- Makefile -*-
+
+EXTRA_DIST = \
+ conf.py \
+ core.rst \
+ index.rst \
+ route_addr.rst \
+ route.rst
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/doc/Makefile.in
new file mode 100644
index 0000000..9835a48
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/Makefile.in
@@ -0,0 +1,446 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python/doc
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+ conf.py \
+ core.rst \
+ index.rst \
+ route_addr.rst \
+ route.rst
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/doc/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/doc/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags TAGS:
+
+ctags CTAGS:
+
+cscope cscopelist:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ cscopelist-am ctags-am distclean distclean-generic \
+ distclean-libtool distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/conf.py b/ap/lib/libnl/libnl-3.2.25/python/doc/conf.py
new file mode 100644
index 0000000..74041f0
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/conf.py
@@ -0,0 +1,216 @@
+# -*- coding: utf-8 -*-
+#
+# libnl-python documentation build configuration file, created by
+# sphinx-quickstart on Mon May 9 10:58:58 2011.
+#
+# This file is execfile()d with the current directory set to its containing dir.
+#
+# Note that not all possible configuration values are present in this
+# autogenerated file.
+#
+# All configuration values have a default; values that are commented out
+# serve to show the default.
+
+import sys, os
+
+# If extensions (or modules to document with autodoc) are in another directory,
+# add these directories to sys.path here. If the directory is relative to the
+# documentation root, use os.path.abspath to make it absolute, like shown here.
+#sys.path.insert(0, os.path.abspath('.'))
+
+# -- General configuration -----------------------------------------------------
+
+# If your documentation needs a minimal Sphinx version, state it here.
+#needs_sphinx = '1.0'
+
+# Add any Sphinx extension module names here, as strings. They can be extensions
+# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
+extensions = ['sphinx.ext.todo', 'sphinx.ext.ifconfig', 'sphinx.ext.viewcode']
+
+# Add any paths that contain templates here, relative to this directory.
+templates_path = ['_templates']
+
+# The suffix of source filenames.
+source_suffix = '.rst'
+
+# The encoding of source files.
+#source_encoding = 'utf-8-sig'
+
+# The master toctree document.
+master_doc = 'index'
+
+# General information about the project.
+project = u'libnl-python'
+copyright = u'2011, Thomas Graf <tgraf@suug.ch>'
+
+# The version info for the project you're documenting, acts as replacement for
+# |version| and |release|, also used in various other places throughout the
+# built documents.
+#
+# The short X.Y version.
+version = '1.0'
+# The full version, including alpha/beta/rc tags.
+release = '1.0'
+
+# The language for content autogenerated by Sphinx. Refer to documentation
+# for a list of supported languages.
+#language = None
+
+# There are two options for replacing |today|: either, you set today to some
+# non-false value, then it is used:
+#today = ''
+# Else, today_fmt is used as the format for a strftime call.
+#today_fmt = '%B %d, %Y'
+
+# List of patterns, relative to source directory, that match files and
+# directories to ignore when looking for source files.
+exclude_patterns = ['_build']
+
+# The reST default role (used for this markup: `text`) to use for all documents.
+#default_role = None
+
+# If true, '()' will be appended to :func: etc. cross-reference text.
+#add_function_parentheses = True
+
+# If true, the current module name will be prepended to all description
+# unit titles (such as .. function::).
+#add_module_names = True
+
+# If true, sectionauthor and moduleauthor directives will be shown in the
+# output. They are ignored by default.
+#show_authors = False
+
+# The name of the Pygments (syntax highlighting) style to use.
+pygments_style = 'sphinx'
+
+# A list of ignored prefixes for module index sorting.
+#modindex_common_prefix = []
+
+
+# -- Options for HTML output ---------------------------------------------------
+
+# The theme to use for HTML and HTML Help pages. See the documentation for
+# a list of builtin themes.
+html_theme = 'default'
+
+# Theme options are theme-specific and customize the look and feel of a theme
+# further. For a list of options available for each theme, see the
+# documentation.
+#html_theme_options = {}
+
+# Add any paths that contain custom themes here, relative to this directory.
+#html_theme_path = []
+
+# The name for this set of Sphinx documents. If None, it defaults to
+# "<project> v<release> documentation".
+#html_title = None
+
+# A shorter title for the navigation bar. Default is the same as html_title.
+#html_short_title = None
+
+# The name of an image file (relative to this directory) to place at the top
+# of the sidebar.
+#html_logo = None
+
+# The name of an image file (within the static path) to use as favicon of the
+# docs. This file should be a Windows icon file (.ico) being 16x16 or 32x32
+# pixels large.
+#html_favicon = None
+
+# Add any paths that contain custom static files (such as style sheets) here,
+# relative to this directory. They are copied after the builtin static files,
+# so a file named "default.css" will overwrite the builtin "default.css".
+html_static_path = ['_static']
+
+# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
+# using the given strftime format.
+#html_last_updated_fmt = '%b %d, %Y'
+
+# If true, SmartyPants will be used to convert quotes and dashes to
+# typographically correct entities.
+#html_use_smartypants = True
+
+# Custom sidebar templates, maps document names to template names.
+#html_sidebars = {}
+
+# Additional templates that should be rendered to pages, maps page names to
+# template names.
+#html_additional_pages = {}
+
+# If false, no module index is generated.
+#html_domain_indices = True
+
+# If false, no index is generated.
+#html_use_index = True
+
+# If true, the index is split into individual pages for each letter.
+#html_split_index = False
+
+# If true, links to the reST sources are added to the pages.
+#html_show_sourcelink = True
+
+# If true, "Created using Sphinx" is shown in the HTML footer. Default is True.
+#html_show_sphinx = True
+
+# If true, "(C) Copyright ..." is shown in the HTML footer. Default is True.
+#html_show_copyright = True
+
+# If true, an OpenSearch description file will be output, and all pages will
+# contain a <link> tag referring to it. The value of this option must be the
+# base URL from which the finished HTML is served.
+#html_use_opensearch = ''
+
+# This is the file name suffix for HTML files (e.g. ".xhtml").
+#html_file_suffix = None
+
+# Output file base name for HTML help builder.
+htmlhelp_basename = 'libnl-pythondoc'
+
+
+# -- Options for LaTeX output --------------------------------------------------
+
+# The paper size ('letter' or 'a4').
+#latex_paper_size = 'letter'
+
+# The font size ('10pt', '11pt' or '12pt').
+#latex_font_size = '10pt'
+
+# Grouping the document tree into LaTeX files. List of tuples
+# (source start file, target name, title, author, documentclass [howto/manual]).
+latex_documents = [
+ ('index', 'libnl-python.tex', u'libnl-python Documentation',
+ u'Thomas Graf \\textless{}tgraf@suug.ch\\textgreater{}', 'manual'),
+]
+
+# The name of an image file (relative to this directory) to place at the top of
+# the title page.
+#latex_logo = None
+
+# For "manual" documents, if this is true, then toplevel headings are parts,
+# not chapters.
+#latex_use_parts = False
+
+# If true, show page references after internal links.
+#latex_show_pagerefs = False
+
+# If true, show URL addresses after external links.
+#latex_show_urls = False
+
+# Additional stuff for the LaTeX preamble.
+#latex_preamble = ''
+
+# Documents to append as an appendix to all manuals.
+#latex_appendices = []
+
+# If false, no module index is generated.
+#latex_domain_indices = True
+
+
+# -- Options for manual page output --------------------------------------------
+
+# One entry per manual page. List of tuples
+# (source start file, name, description, authors, manual section).
+man_pages = [
+ ('index', 'libnl-python', u'libnl-python Documentation',
+ [u'Thomas Graf <tgraf@suug.ch>'], 1)
+]
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/core.rst b/ap/lib/libnl/libnl-3.2.25/python/doc/core.rst
new file mode 100644
index 0000000..012e14c
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/core.rst
@@ -0,0 +1,215 @@
+*******************
+Netlink Core Module
+*******************
+
+.. py:module:: netlink.core
+
+Examples::
+
+ import netlink.core as netlink
+
+===============
+Object
+===============
+
+.. py:class:: Object
+
+ Base class for all classes representing a cacheable object
+
+ Example::
+ obj = netlink.Object("route/link", "link")
+
+ .. py:method:: clone
+
+ Clone the object and return a duplicate (used for COW)
+
+ .. py:method:: dump([params=None])
+
+ Call the libnl internal dump mechanism to dump the object
+ according to the parameters specified.
+
+ .. py:method:: apply(attr, val)
+
+ Applies a attribute=value pair and modifies the object accordingly.
+ Example::
+ obj.apply("mtu", 1200) # Sets attribute mtu to 1200 (link obj)
+
+ :raises: KeyError if attribute is unknown
+ :raises: ImmutableError if attribute is not mutable
+
+ .. py:attribute:: mark
+
+ True if the object is marked, otherwise False.
+
+ .. py:attribute:: shared
+
+ True if the object is used by multiple parties, otherwise False.
+
+ .. py:attribute:: refcnt
+
+ Number of users sharing a reference to the object
+ :rtype: int
+
+ .. py:attribute:: attrs
+
+ List of attributes
+
+ :rtype: list of strings
+
+===============
+Cache
+===============
+
+.. py:class:: Cache
+
+ Base class for all cache implementations.
+
+ A cache is a collection of cacheable objects which is typically used
+ by netlink protocols which handle any kind of object, e.g. network
+ links, network addresses, neighbours, ...
+
+ .. py:method:: subset(filter)
+
+ Returns a new cache containing the subset which matches the
+ provided filter.
+
+ :raises: ValueError if no filter is specified
+ :rtype: :py:class:`Cache`
+
+ .. py:method:: dump([params=None, filter=None])
+
+ Calls the libnl internal dump mechanism to dump the cache according
+ to the parameters and filter specified.
+
+ .. py:method:: clear()
+
+ Remove and possibly destroy all objects in the cache
+
+ .. py:method:: refill([socket=None]) -> :py:class:`Cache`
+
+ Clears and refills the cache with the content which is provided by
+ the kernel, e.g. for a link cache this would mean refilling the
+ cache with all configured network links.
+
+ .. py:method:: provide()
+
+ Caches which have been "provided" are made available to other users
+ (of the same application context) which "require" it. F.e. a link
+ cache is generally provided to allow others to translate interface
+ indexes to link names
+
+
+ .. py:method:: unprovide()
+
+ No longer make the cache available to others. If the cache has been
+ handed out already, that reference will still be valid.
+
+===============
+AbstractAddress
+===============
+
+.. py:class:: AbstractAddress
+
+ Abstract representation of an address. This class is not to be mistaken
+ with :py:class:`route.Address` which represents a configured network
+ address. This class represents the actual address in a family independent
+ way::
+
+ addr = netlink.AbstractAddress('127.0.0.1/8')
+ print addr # => '127.0.0.1/8'
+ print addr.prefixlen # => '8'
+ print addr.family # => 'inet'
+ print len(addr) # => '4' (32bit ipv4 address)
+
+ a = netlink.AbstractAddress('10.0.0.1/24')
+ b = netlink.AbstractAddress('10.0.0.2/24')
+ print a == b # => False
+
+ .. py:attribute:: prefixlen
+
+ Length of prefix in number of bits.
+
+ :rtype: int
+
+ .. py:attribute:: family
+
+ The family type of the address. Setting the address family can be
+ done with a string or a :py:class:`AddressFamily` object.
+
+ :rtype: :py:class:`AddressFamily`
+
+ .. py:attribute:: shared
+
+ True if address is in use by multiple callers, otherwise False
+
+ :rtype: bool
+
+===============
+AddressFamily
+===============
+
+.. py:class:: AddressFamily
+
+ Address family representation::
+
+ af = netlink.AddressFamily('inet6')
+ # raises:
+ # - ValueError if family name is not known
+ # - TypeError if invalid type is specified for family
+
+ print af # => 'inet6' (string representation)
+ print int(af) # => 10 (numeric representation)
+ print repr(af) # => AddressFamily('inet6')
+
+===============
+Exceptions
+===============
+
+.. py:exception:: NetlinkError
+
+ Generic exception raised by netlink modules.
+
+.. py:exception:: KernelError
+
+ Raised if an error occured while communicating with the kernel. Contains
+ the error code returning which is automatically included in the error
+ message.
+
+.. py:exception:: ImmutableError
+
+ Raised if an attribute is modified which is marked immutable.
+
+===============
+Socket
+===============
+
+.. py:class:: Socket
+
+ Netlink socket.
+
+ Note: It is not required to manually create and connect netlink sockets
+ when using caches. The caches will automatically lookup or create a
+ socket as needed.
+
+ .. py:attribute:: local_port
+
+ Local port (address) of netlink socket
+
+ .. py:attribute:: peer_port
+
+ Peer port (remote address) of netlink socket. If set, all messages
+ will be sent to that peer.
+
+ .. py:method:: connect(proto)
+
+ Connect the netlink socket using the specified netlink protocol::
+ sock.connect(netlink.NETLINK_ROUTE)
+
+ .. py:method:: disconnect()
+
+ Disconnect the socket
+
+ .. py:method:: set_bufsize(rx, tx)
+
+ Sets the size of the socket buffer
+
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/index.rst b/ap/lib/libnl/libnl-3.2.25/python/doc/index.rst
new file mode 100644
index 0000000..8de8ae3
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/index.rst
@@ -0,0 +1,24 @@
+.. libnl-python documentation master file, created by
+ sphinx-quickstart on Mon May 9 10:58:58 2011.
+ You can adapt this file completely to your liking, but it should at least
+ contain the root `toctree` directive.
+
+Welcome to libnl-python's documentation!
+========================================
+
+Contents:
+
+.. toctree::
+ :maxdepth: 2
+
+ core
+ route
+ route_addr
+
+Indices and tables
+==================
+
+* :ref:`genindex`
+* :ref:`modindex`
+* :ref:`search`
+
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/route.rst b/ap/lib/libnl/libnl-3.2.25/python/doc/route.rst
new file mode 100644
index 0000000..0b8f3f9
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/route.rst
@@ -0,0 +1,3 @@
+**********************
+Routing
+**********************
diff --git a/ap/lib/libnl/libnl-3.2.25/python/doc/route_addr.rst b/ap/lib/libnl/libnl-3.2.25/python/doc/route_addr.rst
new file mode 100644
index 0000000..2cfe139
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/doc/route_addr.rst
@@ -0,0 +1,47 @@
+=================
+Network Addresses
+=================
+
+The **Address** module provides access to the network address configuration
+of the kernel. It provides an interface to fetch all configured addresses,
+add new addresses and to delete existing addresses.
+
+Fetching the list of network addresses is achieved by creating a new
+address cache::
+
+ import netlink.route.address as Address
+
+ addr_cache = Address.AddressCache()
+ addr_cache.refill()
+
+ for addr in addr_cache:
+ print addr
+
+.. py:module:: netlink.route.addr
+
+
+AddressCache
+------------
+
+.. py:class:: AddressCache
+
+ Represents a cache containing all or a subset of network addresses.
+
+ .. py:method:: lookup(ifindex, local)
+
+ Lookup the address which matches ifindex and local address
+
+ :raises: KeyError if address is not found.
+
+Address
+-------
+
+.. py:class:: Address
+
+ Representation of a configured network address.
+
+ .. py:attribute:: ifindex
+
+ Interface index
+
+ :rtype: int
diff --git a/ap/lib/libnl/libnl-3.2.25/python/examples/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/examples/Makefile.am
new file mode 100644
index 0000000..1cea5e2
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/examples/Makefile.am
@@ -0,0 +1,6 @@
+# -*- Makefile -*-
+
+EXTRA_DIST = \
+ iface.py \
+ nl80211.py \
+ wiphy.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/examples/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/examples/Makefile.in
new file mode 100644
index 0000000..85c2e47
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/examples/Makefile.in
@@ -0,0 +1,444 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python/examples
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+ iface.py \
+ nl80211.py \
+ wiphy.py
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/examples/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/examples/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags TAGS:
+
+ctags CTAGS:
+
+cscope cscopelist:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ cscopelist-am ctags-am distclean distclean-generic \
+ distclean-libtool distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/examples/iface.py b/ap/lib/libnl/libnl-3.2.25/python/examples/iface.py
new file mode 100644
index 0000000..7021882
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/examples/iface.py
@@ -0,0 +1,93 @@
+import netlink.capi as nl
+import netlink.genl.capi as genl
+import nl80211
+import sys
+import traceback
+
+class test_class:
+ def __init__(self):
+ self.done = 1;
+
+def msg_handler(m, a):
+ try:
+ e, attr = genl.py_genlmsg_parse(nl.nlmsg_hdr(m), 0,
+ nl80211.NL80211_ATTR_MAX, None)
+ if nl80211.NL80211_ATTR_WIPHY in attr:
+ thiswiphy = nl.nla_get_u32(attr[nl80211.NL80211_ATTR_WIPHY])
+ print("phy#%d" % thiswiphy)
+ if nl80211.NL80211_ATTR_IFNAME in attr:
+ print("\tinterface %s" % nl.nla_get_string(attr[nl80211.NL80211_ATTR_IFNAME]));
+ if nl80211.NL80211_ATTR_IFINDEX in attr:
+ print("\tifindex %d" % nl.nla_get_u32(attr[nl80211.NL80211_ATTR_IFINDEX]))
+ if nl80211.NL80211_ATTR_WDEV in attr:
+ print("\twdev 0x%lx" % nl.nla_get_u64(attr[nl80211.NL80211_ATTR_WDEV]))
+ if nl80211.NL80211_ATTR_MAC in attr:
+ print("\tmac %02x:%02x:%02x:%02x:%02x:%02x" % tuple(nl.nla_data(attr[nl80211.NL80211_ATTR_MAC])))
+ if nl80211.NL80211_ATTR_SSID in attr:
+ print("\tssid ", nl.nla_data(attr[nl80211.NL80211_ATTR_SSID]))
+ if nl80211.NL80211_ATTR_IFTYPE in attr:
+ iftype = nl.nla_get_u32(attr[nl80211.NL80211_ATTR_IFTYPE])
+ print("\ttype %s" % nl80211.nl80211_iftype2str[iftype])
+ if nl80211.NL80211_ATTR_WIPHY_FREQ in attr:
+ freq = nl.nla_get_u32(attr[nl80211.NL80211_ATTR_WIPHY_FREQ])
+
+ sys.stdout.write("\tfreq %d MHz" % freq);
+
+ if nl80211.NL80211_ATTR_CHANNEL_WIDTH in attr:
+ chanw = nl.nla_get_u32(attr[nl80211.NL80211_ATTR_CHANNEL_WIDTH])
+ sys.stdout.write(", width: %s" % nl80211.nl80211_chan_width2str[chanw])
+ if nl80211.NL80211_ATTR_CENTER_FREQ1 in attr:
+ sys.stdout.write(", center1: %d MHz" %
+ nl.nla_get_u32(attr[nl80211.NL80211_ATTR_CENTER_FREQ1]))
+ if nl80211.NL80211_ATTR_CENTER_FREQ2 in attr:
+ sys.stdout.write(", center2: %d MHz" %
+ nl.nla_get_u32(attr[nl80211.NL80211_ATTR_CENTER_FREQ2]))
+ elif nl80211.NL80211_ATTR_WIPHY_CHANNEL_TYPE in attr:
+ channel_type = nl.nla_get_u32(attr[nl80211.NL80211_ATTR_WIPHY_CHANNEL_TYPE])
+ sys.stdout.write(" %s" % nl80211.nl80211_channel_type2str(channel_type));
+
+ sys.stdout.write("\n");
+ return nl.NL_SKIP;
+ except Exception as e:
+ (t,v,tb) = sys.exc_info()
+ print v.message
+ traceback.print_tb(tb)
+
+def error_handler(err, a):
+ a.done = err.error
+ return nl.NL_STOP
+
+def finish_handler(m, a):
+ return nl.NL_SKIP
+
+def ack_handler(m, a):
+ a.done = 0
+ return nl.NL_STOP
+
+try:
+ cbd = test_class()
+ tx_cb = nl.nl_cb_alloc(nl.NL_CB_DEFAULT)
+ rx_cb = nl.nl_cb_clone(tx_cb)
+ s = nl.nl_socket_alloc_cb(tx_cb)
+ nl.py_nl_cb_err(rx_cb, nl.NL_CB_CUSTOM, error_handler, cbd);
+ nl.py_nl_cb_set(rx_cb, nl.NL_CB_FINISH, nl.NL_CB_CUSTOM, finish_handler, cbd);
+ nl.py_nl_cb_set(rx_cb, nl.NL_CB_ACK, nl.NL_CB_CUSTOM, ack_handler, cbd);
+ nl.py_nl_cb_set(rx_cb, nl.NL_CB_VALID, nl.NL_CB_CUSTOM, msg_handler, cbd);
+
+ genl.genl_connect(s)
+ family = genl.genl_ctrl_resolve(s, 'nl80211')
+ m = nl.nlmsg_alloc()
+ genl.genlmsg_put(m, 0, 0, family, 0, 0, nl80211.NL80211_CMD_GET_INTERFACE, 0)
+ nl.nla_put_u32(m, nl80211.NL80211_ATTR_IFINDEX, nl.if_nametoindex('wlan0'))
+
+ err = nl.nl_send_auto_complete(s, m);
+ if err < 0:
+ nl.nlmsg_free(msg)
+
+ while cbd.done > 0 and not err < 0:
+ err = nl.nl_recvmsgs(s, rx_cb)
+
+except Exception as e:
+ (t, v, tb) = sys.exc_info()
+ print v.message
+ traceback.print_tb(tb)
diff --git a/ap/lib/libnl/libnl-3.2.25/python/examples/nl80211.py b/ap/lib/libnl/libnl-3.2.25/python/examples/nl80211.py
new file mode 100644
index 0000000..7434bef
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/examples/nl80211.py
@@ -0,0 +1,1577 @@
+###########################################################
+# file: nl80211.py
+# ---------------------------------------------------------
+# This file is generated using extract.py using pycparser
+###########################################################
+NL80211_GENL_FAMILY = 'nl80211'
+
+NL80211_CMD_UNSPEC = 0
+NL80211_CMD_GET_WIPHY = 1
+NL80211_CMD_SET_WIPHY = 2
+NL80211_CMD_NEW_WIPHY = 3
+NL80211_CMD_DEL_WIPHY = 4
+NL80211_CMD_GET_INTERFACE = 5
+NL80211_CMD_SET_INTERFACE = 6
+NL80211_CMD_NEW_INTERFACE = 7
+NL80211_CMD_DEL_INTERFACE = 8
+NL80211_CMD_GET_KEY = 9
+NL80211_CMD_SET_KEY = 10
+NL80211_CMD_NEW_KEY = 11
+NL80211_CMD_DEL_KEY = 12
+NL80211_CMD_GET_BEACON = 13
+NL80211_CMD_SET_BEACON = 14
+NL80211_CMD_START_AP = 15
+NL80211_CMD_NEW_BEACON = NL80211_CMD_START_AP
+NL80211_CMD_STOP_AP = 16
+NL80211_CMD_DEL_BEACON = NL80211_CMD_STOP_AP
+NL80211_CMD_GET_STATION = 17
+NL80211_CMD_SET_STATION = 18
+NL80211_CMD_NEW_STATION = 19
+NL80211_CMD_DEL_STATION = 20
+NL80211_CMD_GET_MPATH = 21
+NL80211_CMD_SET_MPATH = 22
+NL80211_CMD_NEW_MPATH = 23
+NL80211_CMD_DEL_MPATH = 24
+NL80211_CMD_SET_BSS = 25
+NL80211_CMD_SET_REG = 26
+NL80211_CMD_REQ_SET_REG = 27
+NL80211_CMD_GET_MESH_CONFIG = 28
+NL80211_CMD_SET_MESH_CONFIG = 29
+NL80211_CMD_SET_MGMT_EXTRA_IE = 30
+NL80211_CMD_GET_REG = 31
+NL80211_CMD_GET_SCAN = 32
+NL80211_CMD_TRIGGER_SCAN = 33
+NL80211_CMD_NEW_SCAN_RESULTS = 34
+NL80211_CMD_SCAN_ABORTED = 35
+NL80211_CMD_REG_CHANGE = 36
+NL80211_CMD_AUTHENTICATE = 37
+NL80211_CMD_ASSOCIATE = 38
+NL80211_CMD_DEAUTHENTICATE = 39
+NL80211_CMD_DISASSOCIATE = 40
+NL80211_CMD_MICHAEL_MIC_FAILURE = 41
+NL80211_CMD_REG_BEACON_HINT = 42
+NL80211_CMD_JOIN_IBSS = 43
+NL80211_CMD_LEAVE_IBSS = 44
+NL80211_CMD_TESTMODE = 45
+NL80211_CMD_CONNECT = 46
+NL80211_CMD_ROAM = 47
+NL80211_CMD_DISCONNECT = 48
+NL80211_CMD_SET_WIPHY_NETNS = 49
+NL80211_CMD_GET_SURVEY = 50
+NL80211_CMD_NEW_SURVEY_RESULTS = 51
+NL80211_CMD_SET_PMKSA = 52
+NL80211_CMD_DEL_PMKSA = 53
+NL80211_CMD_FLUSH_PMKSA = 54
+NL80211_CMD_REMAIN_ON_CHANNEL = 55
+NL80211_CMD_CANCEL_REMAIN_ON_CHANNEL = 56
+NL80211_CMD_SET_TX_BITRATE_MASK = 57
+NL80211_CMD_REGISTER_FRAME = 58
+NL80211_CMD_REGISTER_ACTION = NL80211_CMD_REGISTER_FRAME
+NL80211_CMD_FRAME = 59
+NL80211_CMD_ACTION = NL80211_CMD_FRAME
+NL80211_CMD_FRAME_TX_STATUS = 60
+NL80211_CMD_ACTION_TX_STATUS = NL80211_CMD_FRAME_TX_STATUS
+NL80211_CMD_SET_POWER_SAVE = 61
+NL80211_CMD_GET_POWER_SAVE = 62
+NL80211_CMD_SET_CQM = 63
+NL80211_CMD_NOTIFY_CQM = 64
+NL80211_CMD_SET_CHANNEL = 65
+NL80211_CMD_SET_WDS_PEER = 66
+NL80211_CMD_FRAME_WAIT_CANCEL = 67
+NL80211_CMD_JOIN_MESH = 68
+NL80211_CMD_LEAVE_MESH = 69
+NL80211_CMD_UNPROT_DEAUTHENTICATE = 70
+NL80211_CMD_UNPROT_DISASSOCIATE = 71
+NL80211_CMD_NEW_PEER_CANDIDATE = 72
+NL80211_CMD_GET_WOWLAN = 73
+NL80211_CMD_SET_WOWLAN = 74
+NL80211_CMD_START_SCHED_SCAN = 75
+NL80211_CMD_STOP_SCHED_SCAN = 76
+NL80211_CMD_SCHED_SCAN_RESULTS = 77
+NL80211_CMD_SCHED_SCAN_STOPPED = 78
+NL80211_CMD_SET_REKEY_OFFLOAD = 79
+NL80211_CMD_PMKSA_CANDIDATE = 80
+NL80211_CMD_TDLS_OPER = 81
+NL80211_CMD_TDLS_MGMT = 82
+NL80211_CMD_UNEXPECTED_FRAME = 83
+NL80211_CMD_PROBE_CLIENT = 84
+NL80211_CMD_REGISTER_BEACONS = 85
+NL80211_CMD_UNEXPECTED_4ADDR_FRAME = 86
+NL80211_CMD_SET_NOACK_MAP = 87
+NL80211_CMD_CH_SWITCH_NOTIFY = 88
+NL80211_CMD_START_P2P_DEVICE = 89
+NL80211_CMD_STOP_P2P_DEVICE = 90
+NL80211_CMD_CONN_FAILED = 91
+NL80211_CMD_SET_MCAST_RATE = 92
+NL80211_CMD_SET_MAC_ACL = 93
+NL80211_CMD_RADAR_DETECT = 94
+NL80211_CMD_GET_PROTOCOL_FEATURES = 95
+NL80211_CMD_UPDATE_FT_IES = 96
+NL80211_CMD_FT_EVENT = 97
+NL80211_CMD_CRIT_PROTOCOL_START = 98
+NL80211_CMD_CRIT_PROTOCOL_STOP = 99
+__NL80211_CMD_AFTER_LAST = 100
+NL80211_CMD_MAX = __NL80211_CMD_AFTER_LAST - 1
+NL80211_ATTR_UNSPEC = 0
+NL80211_ATTR_WIPHY = 1
+NL80211_ATTR_WIPHY_NAME = 2
+NL80211_ATTR_IFINDEX = 3
+NL80211_ATTR_IFNAME = 4
+NL80211_ATTR_IFTYPE = 5
+NL80211_ATTR_MAC = 6
+NL80211_ATTR_KEY_DATA = 7
+NL80211_ATTR_KEY_IDX = 8
+NL80211_ATTR_KEY_CIPHER = 9
+NL80211_ATTR_KEY_SEQ = 10
+NL80211_ATTR_KEY_DEFAULT = 11
+NL80211_ATTR_BEACON_INTERVAL = 12
+NL80211_ATTR_DTIM_PERIOD = 13
+NL80211_ATTR_BEACON_HEAD = 14
+NL80211_ATTR_BEACON_TAIL = 15
+NL80211_ATTR_STA_AID = 16
+NL80211_ATTR_STA_FLAGS = 17
+NL80211_ATTR_STA_LISTEN_INTERVAL = 18
+NL80211_ATTR_STA_SUPPORTED_RATES = 19
+NL80211_ATTR_STA_VLAN = 20
+NL80211_ATTR_STA_INFO = 21
+NL80211_ATTR_WIPHY_BANDS = 22
+NL80211_ATTR_MNTR_FLAGS = 23
+NL80211_ATTR_MESH_ID = 24
+NL80211_ATTR_STA_PLINK_ACTION = 25
+NL80211_ATTR_MPATH_NEXT_HOP = 26
+NL80211_ATTR_MPATH_INFO = 27
+NL80211_ATTR_BSS_CTS_PROT = 28
+NL80211_ATTR_BSS_SHORT_PREAMBLE = 29
+NL80211_ATTR_BSS_SHORT_SLOT_TIME = 30
+NL80211_ATTR_HT_CAPABILITY = 31
+NL80211_ATTR_SUPPORTED_IFTYPES = 32
+NL80211_ATTR_REG_ALPHA2 = 33
+NL80211_ATTR_REG_RULES = 34
+NL80211_ATTR_MESH_CONFIG = 35
+NL80211_ATTR_BSS_BASIC_RATES = 36
+NL80211_ATTR_WIPHY_TXQ_PARAMS = 37
+NL80211_ATTR_WIPHY_FREQ = 38
+NL80211_ATTR_WIPHY_CHANNEL_TYPE = 39
+NL80211_ATTR_KEY_DEFAULT_MGMT = 40
+NL80211_ATTR_MGMT_SUBTYPE = 41
+NL80211_ATTR_IE = 42
+NL80211_ATTR_MAX_NUM_SCAN_SSIDS = 43
+NL80211_ATTR_SCAN_FREQUENCIES = 44
+NL80211_ATTR_SCAN_SSIDS = 45
+NL80211_ATTR_GENERATION = 46
+NL80211_ATTR_BSS = 47
+NL80211_ATTR_REG_INITIATOR = 48
+NL80211_ATTR_REG_TYPE = 49
+NL80211_ATTR_SUPPORTED_COMMANDS = 50
+NL80211_ATTR_FRAME = 51
+NL80211_ATTR_SSID = 52
+NL80211_ATTR_AUTH_TYPE = 53
+NL80211_ATTR_REASON_CODE = 54
+NL80211_ATTR_KEY_TYPE = 55
+NL80211_ATTR_MAX_SCAN_IE_LEN = 56
+NL80211_ATTR_CIPHER_SUITES = 57
+NL80211_ATTR_FREQ_BEFORE = 58
+NL80211_ATTR_FREQ_AFTER = 59
+NL80211_ATTR_FREQ_FIXED = 60
+NL80211_ATTR_WIPHY_RETRY_SHORT = 61
+NL80211_ATTR_WIPHY_RETRY_LONG = 62
+NL80211_ATTR_WIPHY_FRAG_THRESHOLD = 63
+NL80211_ATTR_WIPHY_RTS_THRESHOLD = 64
+NL80211_ATTR_TIMED_OUT = 65
+NL80211_ATTR_USE_MFP = 66
+NL80211_ATTR_STA_FLAGS2 = 67
+NL80211_ATTR_CONTROL_PORT = 68
+NL80211_ATTR_TESTDATA = 69
+NL80211_ATTR_PRIVACY = 70
+NL80211_ATTR_DISCONNECTED_BY_AP = 71
+NL80211_ATTR_STATUS_CODE = 72
+NL80211_ATTR_CIPHER_SUITES_PAIRWISE = 73
+NL80211_ATTR_CIPHER_SUITE_GROUP = 74
+NL80211_ATTR_WPA_VERSIONS = 75
+NL80211_ATTR_AKM_SUITES = 76
+NL80211_ATTR_REQ_IE = 77
+NL80211_ATTR_RESP_IE = 78
+NL80211_ATTR_PREV_BSSID = 79
+NL80211_ATTR_KEY = 80
+NL80211_ATTR_KEYS = 81
+NL80211_ATTR_PID = 82
+NL80211_ATTR_4ADDR = 83
+NL80211_ATTR_SURVEY_INFO = 84
+NL80211_ATTR_PMKID = 85
+NL80211_ATTR_MAX_NUM_PMKIDS = 86
+NL80211_ATTR_DURATION = 87
+NL80211_ATTR_COOKIE = 88
+NL80211_ATTR_WIPHY_COVERAGE_CLASS = 89
+NL80211_ATTR_TX_RATES = 90
+NL80211_ATTR_FRAME_MATCH = 91
+NL80211_ATTR_ACK = 92
+NL80211_ATTR_PS_STATE = 93
+NL80211_ATTR_CQM = 94
+NL80211_ATTR_LOCAL_STATE_CHANGE = 95
+NL80211_ATTR_AP_ISOLATE = 96
+NL80211_ATTR_WIPHY_TX_POWER_SETTING = 97
+NL80211_ATTR_WIPHY_TX_POWER_LEVEL = 98
+NL80211_ATTR_TX_FRAME_TYPES = 99
+NL80211_ATTR_RX_FRAME_TYPES = 100
+NL80211_ATTR_FRAME_TYPE = 101
+NL80211_ATTR_CONTROL_PORT_ETHERTYPE = 102
+NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT = 103
+NL80211_ATTR_SUPPORT_IBSS_RSN = 104
+NL80211_ATTR_WIPHY_ANTENNA_TX = 105
+NL80211_ATTR_WIPHY_ANTENNA_RX = 106
+NL80211_ATTR_MCAST_RATE = 107
+NL80211_ATTR_OFFCHANNEL_TX_OK = 108
+NL80211_ATTR_BSS_HT_OPMODE = 109
+NL80211_ATTR_KEY_DEFAULT_TYPES = 110
+NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION = 111
+NL80211_ATTR_MESH_SETUP = 112
+NL80211_ATTR_WIPHY_ANTENNA_AVAIL_TX = 113
+NL80211_ATTR_WIPHY_ANTENNA_AVAIL_RX = 114
+NL80211_ATTR_SUPPORT_MESH_AUTH = 115
+NL80211_ATTR_STA_PLINK_STATE = 116
+NL80211_ATTR_WOWLAN_TRIGGERS = 117
+NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED = 118
+NL80211_ATTR_SCHED_SCAN_INTERVAL = 119
+NL80211_ATTR_INTERFACE_COMBINATIONS = 120
+NL80211_ATTR_SOFTWARE_IFTYPES = 121
+NL80211_ATTR_REKEY_DATA = 122
+NL80211_ATTR_MAX_NUM_SCHED_SCAN_SSIDS = 123
+NL80211_ATTR_MAX_SCHED_SCAN_IE_LEN = 124
+NL80211_ATTR_SCAN_SUPP_RATES = 125
+NL80211_ATTR_HIDDEN_SSID = 126
+NL80211_ATTR_IE_PROBE_RESP = 127
+NL80211_ATTR_IE_ASSOC_RESP = 128
+NL80211_ATTR_STA_WME = 129
+NL80211_ATTR_SUPPORT_AP_UAPSD = 130
+NL80211_ATTR_ROAM_SUPPORT = 131
+NL80211_ATTR_SCHED_SCAN_MATCH = 132
+NL80211_ATTR_MAX_MATCH_SETS = 133
+NL80211_ATTR_PMKSA_CANDIDATE = 134
+NL80211_ATTR_TX_NO_CCK_RATE = 135
+NL80211_ATTR_TDLS_ACTION = 136
+NL80211_ATTR_TDLS_DIALOG_TOKEN = 137
+NL80211_ATTR_TDLS_OPERATION = 138
+NL80211_ATTR_TDLS_SUPPORT = 139
+NL80211_ATTR_TDLS_EXTERNAL_SETUP = 140
+NL80211_ATTR_DEVICE_AP_SME = 141
+NL80211_ATTR_DONT_WAIT_FOR_ACK = 142
+NL80211_ATTR_FEATURE_FLAGS = 143
+NL80211_ATTR_PROBE_RESP_OFFLOAD = 144
+NL80211_ATTR_PROBE_RESP = 145
+NL80211_ATTR_DFS_REGION = 146
+NL80211_ATTR_DISABLE_HT = 147
+NL80211_ATTR_HT_CAPABILITY_MASK = 148
+NL80211_ATTR_NOACK_MAP = 149
+NL80211_ATTR_INACTIVITY_TIMEOUT = 150
+NL80211_ATTR_RX_SIGNAL_DBM = 151
+NL80211_ATTR_BG_SCAN_PERIOD = 152
+NL80211_ATTR_WDEV = 153
+NL80211_ATTR_USER_REG_HINT_TYPE = 154
+NL80211_ATTR_CONN_FAILED_REASON = 155
+NL80211_ATTR_SAE_DATA = 156
+NL80211_ATTR_VHT_CAPABILITY = 157
+NL80211_ATTR_SCAN_FLAGS = 158
+NL80211_ATTR_CHANNEL_WIDTH = 159
+NL80211_ATTR_CENTER_FREQ1 = 160
+NL80211_ATTR_CENTER_FREQ2 = 161
+NL80211_ATTR_P2P_CTWINDOW = 162
+NL80211_ATTR_P2P_OPPPS = 163
+NL80211_ATTR_LOCAL_MESH_POWER_MODE = 164
+NL80211_ATTR_ACL_POLICY = 165
+NL80211_ATTR_MAC_ADDRS = 166
+NL80211_ATTR_MAC_ACL_MAX = 167
+NL80211_ATTR_RADAR_EVENT = 168
+NL80211_ATTR_EXT_CAPA = 169
+NL80211_ATTR_EXT_CAPA_MASK = 170
+NL80211_ATTR_STA_CAPABILITY = 171
+NL80211_ATTR_STA_EXT_CAPABILITY = 172
+NL80211_ATTR_PROTOCOL_FEATURES = 173
+NL80211_ATTR_SPLIT_WIPHY_DUMP = 174
+NL80211_ATTR_DISABLE_VHT = 175
+NL80211_ATTR_VHT_CAPABILITY_MASK = 176
+NL80211_ATTR_MDID = 177
+NL80211_ATTR_IE_RIC = 178
+NL80211_ATTR_CRIT_PROT_ID = 179
+NL80211_ATTR_MAX_CRIT_PROT_DURATION = 180
+NL80211_ATTR_PEER_AID = 181
+__NL80211_ATTR_AFTER_LAST = 182
+NL80211_ATTR_MAX = __NL80211_ATTR_AFTER_LAST - 1
+NL80211_IFTYPE_UNSPECIFIED = 0
+NL80211_IFTYPE_ADHOC = 1
+NL80211_IFTYPE_STATION = 2
+NL80211_IFTYPE_AP = 3
+NL80211_IFTYPE_AP_VLAN = 4
+NL80211_IFTYPE_WDS = 5
+NL80211_IFTYPE_MONITOR = 6
+NL80211_IFTYPE_MESH_POINT = 7
+NL80211_IFTYPE_P2P_CLIENT = 8
+NL80211_IFTYPE_P2P_GO = 9
+NL80211_IFTYPE_P2P_DEVICE = 10
+NUM_NL80211_IFTYPES = 11
+NL80211_IFTYPE_MAX = NUM_NL80211_IFTYPES - 1
+__NL80211_STA_FLAG_INVALID = 0
+NL80211_STA_FLAG_AUTHORIZED = 1
+NL80211_STA_FLAG_SHORT_PREAMBLE = 2
+NL80211_STA_FLAG_WME = 3
+NL80211_STA_FLAG_MFP = 4
+NL80211_STA_FLAG_AUTHENTICATED = 5
+NL80211_STA_FLAG_TDLS_PEER = 6
+NL80211_STA_FLAG_ASSOCIATED = 7
+__NL80211_STA_FLAG_AFTER_LAST = 8
+NL80211_STA_FLAG_MAX = __NL80211_STA_FLAG_AFTER_LAST - 1
+__NL80211_RATE_INFO_INVALID = 0
+NL80211_RATE_INFO_BITRATE = 1
+NL80211_RATE_INFO_MCS = 2
+NL80211_RATE_INFO_40_MHZ_WIDTH = 3
+NL80211_RATE_INFO_SHORT_GI = 4
+NL80211_RATE_INFO_BITRATE32 = 5
+NL80211_RATE_INFO_VHT_MCS = 6
+NL80211_RATE_INFO_VHT_NSS = 7
+NL80211_RATE_INFO_80_MHZ_WIDTH = 8
+NL80211_RATE_INFO_80P80_MHZ_WIDTH = 9
+NL80211_RATE_INFO_160_MHZ_WIDTH = 10
+__NL80211_RATE_INFO_AFTER_LAST = 11
+NL80211_RATE_INFO_MAX = __NL80211_RATE_INFO_AFTER_LAST - 1
+__NL80211_STA_BSS_PARAM_INVALID = 0
+NL80211_STA_BSS_PARAM_CTS_PROT = 1
+NL80211_STA_BSS_PARAM_SHORT_PREAMBLE = 2
+NL80211_STA_BSS_PARAM_SHORT_SLOT_TIME = 3
+NL80211_STA_BSS_PARAM_DTIM_PERIOD = 4
+NL80211_STA_BSS_PARAM_BEACON_INTERVAL = 5
+__NL80211_STA_BSS_PARAM_AFTER_LAST = 6
+NL80211_STA_BSS_PARAM_MAX = __NL80211_STA_BSS_PARAM_AFTER_LAST - 1
+__NL80211_STA_INFO_INVALID = 0
+NL80211_STA_INFO_INACTIVE_TIME = 1
+NL80211_STA_INFO_RX_BYTES = 2
+NL80211_STA_INFO_TX_BYTES = 3
+NL80211_STA_INFO_LLID = 4
+NL80211_STA_INFO_PLID = 5
+NL80211_STA_INFO_PLINK_STATE = 6
+NL80211_STA_INFO_SIGNAL = 7
+NL80211_STA_INFO_TX_BITRATE = 8
+NL80211_STA_INFO_RX_PACKETS = 9
+NL80211_STA_INFO_TX_PACKETS = 10
+NL80211_STA_INFO_TX_RETRIES = 11
+NL80211_STA_INFO_TX_FAILED = 12
+NL80211_STA_INFO_SIGNAL_AVG = 13
+NL80211_STA_INFO_RX_BITRATE = 14
+NL80211_STA_INFO_BSS_PARAM = 15
+NL80211_STA_INFO_CONNECTED_TIME = 16
+NL80211_STA_INFO_STA_FLAGS = 17
+NL80211_STA_INFO_BEACON_LOSS = 18
+NL80211_STA_INFO_T_OFFSET = 19
+NL80211_STA_INFO_LOCAL_PM = 20
+NL80211_STA_INFO_PEER_PM = 21
+NL80211_STA_INFO_NONPEER_PM = 22
+NL80211_STA_INFO_RX_BYTES64 = 23
+NL80211_STA_INFO_TX_BYTES64 = 24
+NL80211_STA_INFO_CHAIN_SIGNAL = 25
+NL80211_STA_INFO_CHAIN_SIGNAL_AVG = 26
+__NL80211_STA_INFO_AFTER_LAST = 27
+NL80211_STA_INFO_MAX = __NL80211_STA_INFO_AFTER_LAST - 1
+NL80211_MPATH_FLAG_ACTIVE = 1 << 0
+NL80211_MPATH_FLAG_RESOLVING = 1 << 1
+NL80211_MPATH_FLAG_SN_VALID = 1 << 2
+NL80211_MPATH_FLAG_FIXED = 1 << 3
+NL80211_MPATH_FLAG_RESOLVED = 1 << 4
+__NL80211_MPATH_INFO_INVALID = 0
+NL80211_MPATH_INFO_FRAME_QLEN = 1
+NL80211_MPATH_INFO_SN = 2
+NL80211_MPATH_INFO_METRIC = 3
+NL80211_MPATH_INFO_EXPTIME = 4
+NL80211_MPATH_INFO_FLAGS = 5
+NL80211_MPATH_INFO_DISCOVERY_TIMEOUT = 6
+NL80211_MPATH_INFO_DISCOVERY_RETRIES = 7
+__NL80211_MPATH_INFO_AFTER_LAST = 8
+NL80211_MPATH_INFO_MAX = __NL80211_MPATH_INFO_AFTER_LAST - 1
+__NL80211_BAND_ATTR_INVALID = 0
+NL80211_BAND_ATTR_FREQS = 1
+NL80211_BAND_ATTR_RATES = 2
+NL80211_BAND_ATTR_HT_MCS_SET = 3
+NL80211_BAND_ATTR_HT_CAPA = 4
+NL80211_BAND_ATTR_HT_AMPDU_FACTOR = 5
+NL80211_BAND_ATTR_HT_AMPDU_DENSITY = 6
+NL80211_BAND_ATTR_VHT_MCS_SET = 7
+NL80211_BAND_ATTR_VHT_CAPA = 8
+__NL80211_BAND_ATTR_AFTER_LAST = 9
+NL80211_BAND_ATTR_MAX = __NL80211_BAND_ATTR_AFTER_LAST - 1
+__NL80211_FREQUENCY_ATTR_INVALID = 0
+NL80211_FREQUENCY_ATTR_FREQ = 1
+NL80211_FREQUENCY_ATTR_DISABLED = 2
+NL80211_FREQUENCY_ATTR_PASSIVE_SCAN = 3
+NL80211_FREQUENCY_ATTR_NO_IBSS = 4
+NL80211_FREQUENCY_ATTR_RADAR = 5
+NL80211_FREQUENCY_ATTR_MAX_TX_POWER = 6
+NL80211_FREQUENCY_ATTR_DFS_STATE = 7
+NL80211_FREQUENCY_ATTR_DFS_TIME = 8
+NL80211_FREQUENCY_ATTR_NO_HT40_MINUS = 9
+NL80211_FREQUENCY_ATTR_NO_HT40_PLUS = 10
+NL80211_FREQUENCY_ATTR_NO_80MHZ = 11
+NL80211_FREQUENCY_ATTR_NO_160MHZ = 12
+__NL80211_FREQUENCY_ATTR_AFTER_LAST = 13
+NL80211_FREQUENCY_ATTR_MAX = __NL80211_FREQUENCY_ATTR_AFTER_LAST - 1
+__NL80211_BITRATE_ATTR_INVALID = 0
+NL80211_BITRATE_ATTR_RATE = 1
+NL80211_BITRATE_ATTR_2GHZ_SHORTPREAMBLE = 2
+__NL80211_BITRATE_ATTR_AFTER_LAST = 3
+NL80211_BITRATE_ATTR_MAX = __NL80211_BITRATE_ATTR_AFTER_LAST - 1
+NL80211_REGDOM_SET_BY_CORE = 0
+NL80211_REGDOM_SET_BY_USER = 1
+NL80211_REGDOM_SET_BY_DRIVER = 2
+NL80211_REGDOM_SET_BY_COUNTRY_IE = 3
+NL80211_REGDOM_TYPE_COUNTRY = 0
+NL80211_REGDOM_TYPE_WORLD = 1
+NL80211_REGDOM_TYPE_CUSTOM_WORLD = 2
+NL80211_REGDOM_TYPE_INTERSECTION = 3
+__NL80211_REG_RULE_ATTR_INVALID = 0
+NL80211_ATTR_REG_RULE_FLAGS = 1
+NL80211_ATTR_FREQ_RANGE_START = 2
+NL80211_ATTR_FREQ_RANGE_END = 3
+NL80211_ATTR_FREQ_RANGE_MAX_BW = 4
+NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN = 5
+NL80211_ATTR_POWER_RULE_MAX_EIRP = 6
+__NL80211_REG_RULE_ATTR_AFTER_LAST = 7
+NL80211_REG_RULE_ATTR_MAX = __NL80211_REG_RULE_ATTR_AFTER_LAST - 1
+__NL80211_SCHED_SCAN_MATCH_ATTR_INVALID = 0
+NL80211_SCHED_SCAN_MATCH_ATTR_SSID = 1
+NL80211_SCHED_SCAN_MATCH_ATTR_RSSI = 2
+__NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST = 3
+NL80211_SCHED_SCAN_MATCH_ATTR_MAX = __NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST - 1
+NL80211_RRF_NO_OFDM = 1 << 0
+NL80211_RRF_NO_CCK = 1 << 1
+NL80211_RRF_NO_INDOOR = 1 << 2
+NL80211_RRF_NO_OUTDOOR = 1 << 3
+NL80211_RRF_DFS = 1 << 4
+NL80211_RRF_PTP_ONLY = 1 << 5
+NL80211_RRF_PTMP_ONLY = 1 << 6
+NL80211_RRF_PASSIVE_SCAN = 1 << 7
+NL80211_RRF_NO_IBSS = 1 << 8
+NL80211_DFS_UNSET = 0
+NL80211_DFS_FCC = 1
+NL80211_DFS_ETSI = 2
+NL80211_DFS_JP = 3
+NL80211_USER_REG_HINT_USER = 0
+NL80211_USER_REG_HINT_CELL_BASE = 1
+__NL80211_SURVEY_INFO_INVALID = 0
+NL80211_SURVEY_INFO_FREQUENCY = 1
+NL80211_SURVEY_INFO_NOISE = 2
+NL80211_SURVEY_INFO_IN_USE = 3
+NL80211_SURVEY_INFO_CHANNEL_TIME = 4
+NL80211_SURVEY_INFO_CHANNEL_TIME_BUSY = 5
+NL80211_SURVEY_INFO_CHANNEL_TIME_EXT_BUSY = 6
+NL80211_SURVEY_INFO_CHANNEL_TIME_RX = 7
+NL80211_SURVEY_INFO_CHANNEL_TIME_TX = 8
+__NL80211_SURVEY_INFO_AFTER_LAST = 9
+NL80211_SURVEY_INFO_MAX = __NL80211_SURVEY_INFO_AFTER_LAST - 1
+__NL80211_MNTR_FLAG_INVALID = 0
+NL80211_MNTR_FLAG_FCSFAIL = 1
+NL80211_MNTR_FLAG_PLCPFAIL = 2
+NL80211_MNTR_FLAG_CONTROL = 3
+NL80211_MNTR_FLAG_OTHER_BSS = 4
+NL80211_MNTR_FLAG_COOK_FRAMES = 5
+NL80211_MNTR_FLAG_ACTIVE = 6
+__NL80211_MNTR_FLAG_AFTER_LAST = 7
+NL80211_MNTR_FLAG_MAX = __NL80211_MNTR_FLAG_AFTER_LAST - 1
+NL80211_MESH_POWER_UNKNOWN = 0
+NL80211_MESH_POWER_ACTIVE = 1
+NL80211_MESH_POWER_LIGHT_SLEEP = 2
+NL80211_MESH_POWER_DEEP_SLEEP = 3
+__NL80211_MESH_POWER_AFTER_LAST = 4
+NL80211_MESH_POWER_MAX = __NL80211_MESH_POWER_AFTER_LAST - 1
+__NL80211_MESHCONF_INVALID = 0
+NL80211_MESHCONF_RETRY_TIMEOUT = 1
+NL80211_MESHCONF_CONFIRM_TIMEOUT = 2
+NL80211_MESHCONF_HOLDING_TIMEOUT = 3
+NL80211_MESHCONF_MAX_PEER_LINKS = 4
+NL80211_MESHCONF_MAX_RETRIES = 5
+NL80211_MESHCONF_TTL = 6
+NL80211_MESHCONF_AUTO_OPEN_PLINKS = 7
+NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES = 8
+NL80211_MESHCONF_PATH_REFRESH_TIME = 9
+NL80211_MESHCONF_MIN_DISCOVERY_TIMEOUT = 10
+NL80211_MESHCONF_HWMP_ACTIVE_PATH_TIMEOUT = 11
+NL80211_MESHCONF_HWMP_PREQ_MIN_INTERVAL = 12
+NL80211_MESHCONF_HWMP_NET_DIAM_TRVS_TIME = 13
+NL80211_MESHCONF_HWMP_ROOTMODE = 14
+NL80211_MESHCONF_ELEMENT_TTL = 15
+NL80211_MESHCONF_HWMP_RANN_INTERVAL = 16
+NL80211_MESHCONF_GATE_ANNOUNCEMENTS = 17
+NL80211_MESHCONF_HWMP_PERR_MIN_INTERVAL = 18
+NL80211_MESHCONF_FORWARDING = 19
+NL80211_MESHCONF_RSSI_THRESHOLD = 20
+NL80211_MESHCONF_SYNC_OFFSET_MAX_NEIGHBOR = 21
+NL80211_MESHCONF_HT_OPMODE = 22
+NL80211_MESHCONF_HWMP_PATH_TO_ROOT_TIMEOUT = 23
+NL80211_MESHCONF_HWMP_ROOT_INTERVAL = 24
+NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL = 25
+NL80211_MESHCONF_POWER_MODE = 26
+NL80211_MESHCONF_AWAKE_WINDOW = 27
+NL80211_MESHCONF_PLINK_TIMEOUT = 28
+__NL80211_MESHCONF_ATTR_AFTER_LAST = 29
+NL80211_MESHCONF_ATTR_MAX = __NL80211_MESHCONF_ATTR_AFTER_LAST - 1
+__NL80211_MESH_SETUP_INVALID = 0
+NL80211_MESH_SETUP_ENABLE_VENDOR_PATH_SEL = 1
+NL80211_MESH_SETUP_ENABLE_VENDOR_METRIC = 2
+NL80211_MESH_SETUP_IE = 3
+NL80211_MESH_SETUP_USERSPACE_AUTH = 4
+NL80211_MESH_SETUP_USERSPACE_AMPE = 5
+NL80211_MESH_SETUP_ENABLE_VENDOR_SYNC = 6
+NL80211_MESH_SETUP_USERSPACE_MPM = 7
+NL80211_MESH_SETUP_AUTH_PROTOCOL = 8
+__NL80211_MESH_SETUP_ATTR_AFTER_LAST = 9
+NL80211_MESH_SETUP_ATTR_MAX = __NL80211_MESH_SETUP_ATTR_AFTER_LAST - 1
+__NL80211_TXQ_ATTR_INVALID = 0
+NL80211_TXQ_ATTR_AC = 1
+NL80211_TXQ_ATTR_TXOP = 2
+NL80211_TXQ_ATTR_CWMIN = 3
+NL80211_TXQ_ATTR_CWMAX = 4
+NL80211_TXQ_ATTR_AIFS = 5
+__NL80211_TXQ_ATTR_AFTER_LAST = 6
+NL80211_TXQ_ATTR_MAX = __NL80211_TXQ_ATTR_AFTER_LAST - 1
+NL80211_AC_VO = 0
+NL80211_AC_VI = 1
+NL80211_AC_BE = 2
+NL80211_AC_BK = 3
+NL80211_NUM_ACS = 4
+NL80211_CHAN_NO_HT = 0
+NL80211_CHAN_HT20 = 1
+NL80211_CHAN_HT40MINUS = 2
+NL80211_CHAN_HT40PLUS = 3
+NL80211_CHAN_WIDTH_20_NOHT = 0
+NL80211_CHAN_WIDTH_20 = 1
+NL80211_CHAN_WIDTH_40 = 2
+NL80211_CHAN_WIDTH_80 = 3
+NL80211_CHAN_WIDTH_80P80 = 4
+NL80211_CHAN_WIDTH_160 = 5
+__NL80211_BSS_INVALID = 0
+NL80211_BSS_BSSID = 1
+NL80211_BSS_FREQUENCY = 2
+NL80211_BSS_TSF = 3
+NL80211_BSS_BEACON_INTERVAL = 4
+NL80211_BSS_CAPABILITY = 5
+NL80211_BSS_INFORMATION_ELEMENTS = 6
+NL80211_BSS_SIGNAL_MBM = 7
+NL80211_BSS_SIGNAL_UNSPEC = 8
+NL80211_BSS_STATUS = 9
+NL80211_BSS_SEEN_MS_AGO = 10
+NL80211_BSS_BEACON_IES = 11
+__NL80211_BSS_AFTER_LAST = 12
+NL80211_BSS_MAX = __NL80211_BSS_AFTER_LAST - 1
+NL80211_BSS_STATUS_AUTHENTICATED = 0
+NL80211_BSS_STATUS_ASSOCIATED = 1
+NL80211_BSS_STATUS_IBSS_JOINED = 2
+NL80211_AUTHTYPE_OPEN_SYSTEM = 0
+NL80211_AUTHTYPE_SHARED_KEY = 1
+NL80211_AUTHTYPE_FT = 2
+NL80211_AUTHTYPE_NETWORK_EAP = 3
+NL80211_AUTHTYPE_SAE = 4
+__NL80211_AUTHTYPE_NUM = 5
+NL80211_AUTHTYPE_MAX = __NL80211_AUTHTYPE_NUM - 1
+NL80211_AUTHTYPE_AUTOMATIC = 6
+NL80211_KEYTYPE_GROUP = 0
+NL80211_KEYTYPE_PAIRWISE = 1
+NL80211_KEYTYPE_PEERKEY = 2
+NUM_NL80211_KEYTYPES = 3
+NL80211_MFP_NO = 0
+NL80211_MFP_REQUIRED = 1
+NL80211_WPA_VERSION_1 = 1 << 0
+NL80211_WPA_VERSION_2 = 1 << 1
+__NL80211_KEY_DEFAULT_TYPE_INVALID = 0
+NL80211_KEY_DEFAULT_TYPE_UNICAST = 1
+NL80211_KEY_DEFAULT_TYPE_MULTICAST = 2
+NUM_NL80211_KEY_DEFAULT_TYPES = 3
+__NL80211_KEY_INVALID = 0
+NL80211_KEY_DATA = 1
+NL80211_KEY_IDX = 2
+NL80211_KEY_CIPHER = 3
+NL80211_KEY_SEQ = 4
+NL80211_KEY_DEFAULT = 5
+NL80211_KEY_DEFAULT_MGMT = 6
+NL80211_KEY_TYPE = 7
+NL80211_KEY_DEFAULT_TYPES = 8
+__NL80211_KEY_AFTER_LAST = 9
+NL80211_KEY_MAX = __NL80211_KEY_AFTER_LAST - 1
+__NL80211_TXRATE_INVALID = 0
+NL80211_TXRATE_LEGACY = 1
+NL80211_TXRATE_MCS = 2
+__NL80211_TXRATE_AFTER_LAST = 3
+NL80211_TXRATE_MAX = __NL80211_TXRATE_AFTER_LAST - 1
+NL80211_BAND_2GHZ = 0
+NL80211_BAND_5GHZ = 1
+NL80211_BAND_60GHZ = 2
+NL80211_PS_DISABLED = 0
+NL80211_PS_ENABLED = 1
+__NL80211_ATTR_CQM_INVALID = 0
+NL80211_ATTR_CQM_RSSI_THOLD = 1
+NL80211_ATTR_CQM_RSSI_HYST = 2
+NL80211_ATTR_CQM_RSSI_THRESHOLD_EVENT = 3
+NL80211_ATTR_CQM_PKT_LOSS_EVENT = 4
+NL80211_ATTR_CQM_TXE_RATE = 5
+NL80211_ATTR_CQM_TXE_PKTS = 6
+NL80211_ATTR_CQM_TXE_INTVL = 7
+__NL80211_ATTR_CQM_AFTER_LAST = 8
+NL80211_ATTR_CQM_MAX = __NL80211_ATTR_CQM_AFTER_LAST - 1
+NL80211_CQM_RSSI_THRESHOLD_EVENT_LOW = 0
+NL80211_CQM_RSSI_THRESHOLD_EVENT_HIGH = 1
+NL80211_CQM_RSSI_BEACON_LOSS_EVENT = 2
+NL80211_TX_POWER_AUTOMATIC = 0
+NL80211_TX_POWER_LIMITED = 1
+NL80211_TX_POWER_FIXED = 2
+__NL80211_WOWLAN_PKTPAT_INVALID = 0
+NL80211_WOWLAN_PKTPAT_MASK = 1
+NL80211_WOWLAN_PKTPAT_PATTERN = 2
+NL80211_WOWLAN_PKTPAT_OFFSET = 3
+NUM_NL80211_WOWLAN_PKTPAT = 4
+MAX_NL80211_WOWLAN_PKTPAT = NUM_NL80211_WOWLAN_PKTPAT - 1
+__NL80211_WOWLAN_TRIG_INVALID = 0
+NL80211_WOWLAN_TRIG_ANY = 1
+NL80211_WOWLAN_TRIG_DISCONNECT = 2
+NL80211_WOWLAN_TRIG_MAGIC_PKT = 3
+NL80211_WOWLAN_TRIG_PKT_PATTERN = 4
+NL80211_WOWLAN_TRIG_GTK_REKEY_SUPPORTED = 5
+NL80211_WOWLAN_TRIG_GTK_REKEY_FAILURE = 6
+NL80211_WOWLAN_TRIG_EAP_IDENT_REQUEST = 7
+NL80211_WOWLAN_TRIG_4WAY_HANDSHAKE = 8
+NL80211_WOWLAN_TRIG_RFKILL_RELEASE = 9
+NL80211_WOWLAN_TRIG_WAKEUP_PKT_80211 = 10
+NL80211_WOWLAN_TRIG_WAKEUP_PKT_80211_LEN = 11
+NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023 = 12
+NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023_LEN = 13
+NL80211_WOWLAN_TRIG_TCP_CONNECTION = 14
+NL80211_WOWLAN_TRIG_WAKEUP_TCP_MATCH = 15
+NL80211_WOWLAN_TRIG_WAKEUP_TCP_CONNLOST = 16
+NL80211_WOWLAN_TRIG_WAKEUP_TCP_NOMORETOKENS = 17
+NUM_NL80211_WOWLAN_TRIG = 18
+MAX_NL80211_WOWLAN_TRIG = NUM_NL80211_WOWLAN_TRIG - 1
+__NL80211_WOWLAN_TCP_INVALID = 0
+NL80211_WOWLAN_TCP_SRC_IPV4 = 1
+NL80211_WOWLAN_TCP_DST_IPV4 = 2
+NL80211_WOWLAN_TCP_DST_MAC = 3
+NL80211_WOWLAN_TCP_SRC_PORT = 4
+NL80211_WOWLAN_TCP_DST_PORT = 5
+NL80211_WOWLAN_TCP_DATA_PAYLOAD = 6
+NL80211_WOWLAN_TCP_DATA_PAYLOAD_SEQ = 7
+NL80211_WOWLAN_TCP_DATA_PAYLOAD_TOKEN = 8
+NL80211_WOWLAN_TCP_DATA_INTERVAL = 9
+NL80211_WOWLAN_TCP_WAKE_PAYLOAD = 10
+NL80211_WOWLAN_TCP_WAKE_MASK = 11
+NUM_NL80211_WOWLAN_TCP = 12
+MAX_NL80211_WOWLAN_TCP = NUM_NL80211_WOWLAN_TCP - 1
+NL80211_IFACE_LIMIT_UNSPEC = 0
+NL80211_IFACE_LIMIT_MAX = 1
+NL80211_IFACE_LIMIT_TYPES = 2
+NUM_NL80211_IFACE_LIMIT = 3
+MAX_NL80211_IFACE_LIMIT = NUM_NL80211_IFACE_LIMIT - 1
+NL80211_IFACE_COMB_UNSPEC = 0
+NL80211_IFACE_COMB_LIMITS = 1
+NL80211_IFACE_COMB_MAXNUM = 2
+NL80211_IFACE_COMB_STA_AP_BI_MATCH = 3
+NL80211_IFACE_COMB_NUM_CHANNELS = 4
+NL80211_IFACE_COMB_RADAR_DETECT_WIDTHS = 5
+NUM_NL80211_IFACE_COMB = 6
+MAX_NL80211_IFACE_COMB = NUM_NL80211_IFACE_COMB - 1
+NL80211_PLINK_LISTEN = 0
+NL80211_PLINK_OPN_SNT = 1
+NL80211_PLINK_OPN_RCVD = 2
+NL80211_PLINK_CNF_RCVD = 3
+NL80211_PLINK_ESTAB = 4
+NL80211_PLINK_HOLDING = 5
+NL80211_PLINK_BLOCKED = 6
+NUM_NL80211_PLINK_STATES = 7
+MAX_NL80211_PLINK_STATES = NUM_NL80211_PLINK_STATES - 1
+NL80211_PLINK_ACTION_NO_ACTION = 0
+NL80211_PLINK_ACTION_OPEN = 1
+NL80211_PLINK_ACTION_BLOCK = 2
+NUM_NL80211_PLINK_ACTIONS = 3
+__NL80211_REKEY_DATA_INVALID = 0
+NL80211_REKEY_DATA_KEK = 1
+NL80211_REKEY_DATA_KCK = 2
+NL80211_REKEY_DATA_REPLAY_CTR = 3
+NUM_NL80211_REKEY_DATA = 4
+MAX_NL80211_REKEY_DATA = NUM_NL80211_REKEY_DATA - 1
+NL80211_HIDDEN_SSID_NOT_IN_USE = 0
+NL80211_HIDDEN_SSID_ZERO_LEN = 1
+NL80211_HIDDEN_SSID_ZERO_CONTENTS = 2
+__NL80211_STA_WME_INVALID = 0
+NL80211_STA_WME_UAPSD_QUEUES = 1
+NL80211_STA_WME_MAX_SP = 2
+__NL80211_STA_WME_AFTER_LAST = 3
+NL80211_STA_WME_MAX = __NL80211_STA_WME_AFTER_LAST - 1
+__NL80211_PMKSA_CANDIDATE_INVALID = 0
+NL80211_PMKSA_CANDIDATE_INDEX = 1
+NL80211_PMKSA_CANDIDATE_BSSID = 2
+NL80211_PMKSA_CANDIDATE_PREAUTH = 3
+NUM_NL80211_PMKSA_CANDIDATE = 4
+MAX_NL80211_PMKSA_CANDIDATE = NUM_NL80211_PMKSA_CANDIDATE - 1
+NL80211_TDLS_DISCOVERY_REQ = 0
+NL80211_TDLS_SETUP = 1
+NL80211_TDLS_TEARDOWN = 2
+NL80211_TDLS_ENABLE_LINK = 3
+NL80211_TDLS_DISABLE_LINK = 4
+NL80211_FEATURE_SK_TX_STATUS = 1 << 0
+NL80211_FEATURE_HT_IBSS = 1 << 1
+NL80211_FEATURE_INACTIVITY_TIMER = 1 << 2
+NL80211_FEATURE_CELL_BASE_REG_HINTS = 1 << 3
+NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL = 1 << 4
+NL80211_FEATURE_SAE = 1 << 5
+NL80211_FEATURE_LOW_PRIORITY_SCAN = 1 << 6
+NL80211_FEATURE_SCAN_FLUSH = 1 << 7
+NL80211_FEATURE_AP_SCAN = 1 << 8
+NL80211_FEATURE_VIF_TXPOWER = 1 << 9
+NL80211_FEATURE_NEED_OBSS_SCAN = 1 << 10
+NL80211_FEATURE_P2P_GO_CTWIN = 1 << 11
+NL80211_FEATURE_P2P_GO_OPPPS = 1 << 12
+NL80211_FEATURE_ADVERTISE_CHAN_LIMITS = 1 << 14
+NL80211_FEATURE_FULL_AP_CLIENT_STATE = 1 << 15
+NL80211_FEATURE_USERSPACE_MPM = 1 << 16
+NL80211_FEATURE_ACTIVE_MONITOR = 1 << 17
+NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS = 1 << 0
+NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS2 = 1 << 1
+NL80211_PROBE_RESP_OFFLOAD_SUPPORT_P2P = 1 << 2
+NL80211_PROBE_RESP_OFFLOAD_SUPPORT_80211U = 1 << 3
+NL80211_CONN_FAIL_MAX_CLIENTS = 0
+NL80211_CONN_FAIL_BLOCKED_CLIENT = 1
+NL80211_SCAN_FLAG_LOW_PRIORITY = 1 << 0
+NL80211_SCAN_FLAG_FLUSH = 1 << 1
+NL80211_SCAN_FLAG_AP = 1 << 2
+NL80211_ACL_POLICY_ACCEPT_UNLESS_LISTED = 0
+NL80211_ACL_POLICY_DENY_UNLESS_LISTED = 1
+NL80211_RADAR_DETECTED = 0
+NL80211_RADAR_CAC_FINISHED = 1
+NL80211_RADAR_CAC_ABORTED = 2
+NL80211_RADAR_NOP_FINISHED = 3
+NL80211_DFS_USABLE = 0
+NL80211_DFS_UNAVAILABLE = 1
+NL80211_DFS_AVAILABLE = 2
+NL80211_PROTOCOL_FEATURE_SPLIT_WIPHY_DUMP = 1 << 0
+NL80211_CRIT_PROTO_UNSPEC = 0
+NL80211_CRIT_PROTO_DHCP = 1
+NL80211_CRIT_PROTO_EAPOL = 2
+NL80211_CRIT_PROTO_APIPA = 3
+NUM_NL80211_CRIT_PROTO = 4
+nl80211_commands2str = {
+ NL80211_CMD_UNSPEC: "NL80211_CMD_UNSPEC",
+ NL80211_CMD_GET_WIPHY: "NL80211_CMD_GET_WIPHY",
+ NL80211_CMD_SET_WIPHY: "NL80211_CMD_SET_WIPHY",
+ NL80211_CMD_NEW_WIPHY: "NL80211_CMD_NEW_WIPHY",
+ NL80211_CMD_DEL_WIPHY: "NL80211_CMD_DEL_WIPHY",
+ NL80211_CMD_GET_INTERFACE: "NL80211_CMD_GET_INTERFACE",
+ NL80211_CMD_SET_INTERFACE: "NL80211_CMD_SET_INTERFACE",
+ NL80211_CMD_NEW_INTERFACE: "NL80211_CMD_NEW_INTERFACE",
+ NL80211_CMD_DEL_INTERFACE: "NL80211_CMD_DEL_INTERFACE",
+ NL80211_CMD_GET_KEY: "NL80211_CMD_GET_KEY",
+ NL80211_CMD_SET_KEY: "NL80211_CMD_SET_KEY",
+ NL80211_CMD_NEW_KEY: "NL80211_CMD_NEW_KEY",
+ NL80211_CMD_DEL_KEY: "NL80211_CMD_DEL_KEY",
+ NL80211_CMD_GET_BEACON: "NL80211_CMD_GET_BEACON",
+ NL80211_CMD_SET_BEACON: "NL80211_CMD_SET_BEACON",
+ NL80211_CMD_START_AP: "NL80211_CMD_START_AP",
+ NL80211_CMD_STOP_AP: "NL80211_CMD_STOP_AP",
+ NL80211_CMD_GET_STATION: "NL80211_CMD_GET_STATION",
+ NL80211_CMD_SET_STATION: "NL80211_CMD_SET_STATION",
+ NL80211_CMD_NEW_STATION: "NL80211_CMD_NEW_STATION",
+ NL80211_CMD_DEL_STATION: "NL80211_CMD_DEL_STATION",
+ NL80211_CMD_GET_MPATH: "NL80211_CMD_GET_MPATH",
+ NL80211_CMD_SET_MPATH: "NL80211_CMD_SET_MPATH",
+ NL80211_CMD_NEW_MPATH: "NL80211_CMD_NEW_MPATH",
+ NL80211_CMD_DEL_MPATH: "NL80211_CMD_DEL_MPATH",
+ NL80211_CMD_SET_BSS: "NL80211_CMD_SET_BSS",
+ NL80211_CMD_SET_REG: "NL80211_CMD_SET_REG",
+ NL80211_CMD_REQ_SET_REG: "NL80211_CMD_REQ_SET_REG",
+ NL80211_CMD_GET_MESH_CONFIG: "NL80211_CMD_GET_MESH_CONFIG",
+ NL80211_CMD_SET_MESH_CONFIG: "NL80211_CMD_SET_MESH_CONFIG",
+ NL80211_CMD_SET_MGMT_EXTRA_IE: "NL80211_CMD_SET_MGMT_EXTRA_IE",
+ NL80211_CMD_GET_REG: "NL80211_CMD_GET_REG",
+ NL80211_CMD_GET_SCAN: "NL80211_CMD_GET_SCAN",
+ NL80211_CMD_TRIGGER_SCAN: "NL80211_CMD_TRIGGER_SCAN",
+ NL80211_CMD_NEW_SCAN_RESULTS: "NL80211_CMD_NEW_SCAN_RESULTS",
+ NL80211_CMD_SCAN_ABORTED: "NL80211_CMD_SCAN_ABORTED",
+ NL80211_CMD_REG_CHANGE: "NL80211_CMD_REG_CHANGE",
+ NL80211_CMD_AUTHENTICATE: "NL80211_CMD_AUTHENTICATE",
+ NL80211_CMD_ASSOCIATE: "NL80211_CMD_ASSOCIATE",
+ NL80211_CMD_DEAUTHENTICATE: "NL80211_CMD_DEAUTHENTICATE",
+ NL80211_CMD_DISASSOCIATE: "NL80211_CMD_DISASSOCIATE",
+ NL80211_CMD_MICHAEL_MIC_FAILURE: "NL80211_CMD_MICHAEL_MIC_FAILURE",
+ NL80211_CMD_REG_BEACON_HINT: "NL80211_CMD_REG_BEACON_HINT",
+ NL80211_CMD_JOIN_IBSS: "NL80211_CMD_JOIN_IBSS",
+ NL80211_CMD_LEAVE_IBSS: "NL80211_CMD_LEAVE_IBSS",
+ NL80211_CMD_TESTMODE: "NL80211_CMD_TESTMODE",
+ NL80211_CMD_CONNECT: "NL80211_CMD_CONNECT",
+ NL80211_CMD_ROAM: "NL80211_CMD_ROAM",
+ NL80211_CMD_DISCONNECT: "NL80211_CMD_DISCONNECT",
+ NL80211_CMD_SET_WIPHY_NETNS: "NL80211_CMD_SET_WIPHY_NETNS",
+ NL80211_CMD_GET_SURVEY: "NL80211_CMD_GET_SURVEY",
+ NL80211_CMD_NEW_SURVEY_RESULTS: "NL80211_CMD_NEW_SURVEY_RESULTS",
+ NL80211_CMD_SET_PMKSA: "NL80211_CMD_SET_PMKSA",
+ NL80211_CMD_DEL_PMKSA: "NL80211_CMD_DEL_PMKSA",
+ NL80211_CMD_FLUSH_PMKSA: "NL80211_CMD_FLUSH_PMKSA",
+ NL80211_CMD_REMAIN_ON_CHANNEL: "NL80211_CMD_REMAIN_ON_CHANNEL",
+ NL80211_CMD_CANCEL_REMAIN_ON_CHANNEL: "NL80211_CMD_CANCEL_REMAIN_ON_CHANNEL",
+ NL80211_CMD_SET_TX_BITRATE_MASK: "NL80211_CMD_SET_TX_BITRATE_MASK",
+ NL80211_CMD_REGISTER_FRAME: "NL80211_CMD_REGISTER_FRAME",
+ NL80211_CMD_FRAME: "NL80211_CMD_FRAME",
+ NL80211_CMD_FRAME_TX_STATUS: "NL80211_CMD_FRAME_TX_STATUS",
+ NL80211_CMD_SET_POWER_SAVE: "NL80211_CMD_SET_POWER_SAVE",
+ NL80211_CMD_GET_POWER_SAVE: "NL80211_CMD_GET_POWER_SAVE",
+ NL80211_CMD_SET_CQM: "NL80211_CMD_SET_CQM",
+ NL80211_CMD_NOTIFY_CQM: "NL80211_CMD_NOTIFY_CQM",
+ NL80211_CMD_SET_CHANNEL: "NL80211_CMD_SET_CHANNEL",
+ NL80211_CMD_SET_WDS_PEER: "NL80211_CMD_SET_WDS_PEER",
+ NL80211_CMD_FRAME_WAIT_CANCEL: "NL80211_CMD_FRAME_WAIT_CANCEL",
+ NL80211_CMD_JOIN_MESH: "NL80211_CMD_JOIN_MESH",
+ NL80211_CMD_LEAVE_MESH: "NL80211_CMD_LEAVE_MESH",
+ NL80211_CMD_UNPROT_DEAUTHENTICATE: "NL80211_CMD_UNPROT_DEAUTHENTICATE",
+ NL80211_CMD_UNPROT_DISASSOCIATE: "NL80211_CMD_UNPROT_DISASSOCIATE",
+ NL80211_CMD_NEW_PEER_CANDIDATE: "NL80211_CMD_NEW_PEER_CANDIDATE",
+ NL80211_CMD_GET_WOWLAN: "NL80211_CMD_GET_WOWLAN",
+ NL80211_CMD_SET_WOWLAN: "NL80211_CMD_SET_WOWLAN",
+ NL80211_CMD_START_SCHED_SCAN: "NL80211_CMD_START_SCHED_SCAN",
+ NL80211_CMD_STOP_SCHED_SCAN: "NL80211_CMD_STOP_SCHED_SCAN",
+ NL80211_CMD_SCHED_SCAN_RESULTS: "NL80211_CMD_SCHED_SCAN_RESULTS",
+ NL80211_CMD_SCHED_SCAN_STOPPED: "NL80211_CMD_SCHED_SCAN_STOPPED",
+ NL80211_CMD_SET_REKEY_OFFLOAD: "NL80211_CMD_SET_REKEY_OFFLOAD",
+ NL80211_CMD_PMKSA_CANDIDATE: "NL80211_CMD_PMKSA_CANDIDATE",
+ NL80211_CMD_TDLS_OPER: "NL80211_CMD_TDLS_OPER",
+ NL80211_CMD_TDLS_MGMT: "NL80211_CMD_TDLS_MGMT",
+ NL80211_CMD_UNEXPECTED_FRAME: "NL80211_CMD_UNEXPECTED_FRAME",
+ NL80211_CMD_PROBE_CLIENT: "NL80211_CMD_PROBE_CLIENT",
+ NL80211_CMD_REGISTER_BEACONS: "NL80211_CMD_REGISTER_BEACONS",
+ NL80211_CMD_UNEXPECTED_4ADDR_FRAME: "NL80211_CMD_UNEXPECTED_4ADDR_FRAME",
+ NL80211_CMD_SET_NOACK_MAP: "NL80211_CMD_SET_NOACK_MAP",
+ NL80211_CMD_CH_SWITCH_NOTIFY: "NL80211_CMD_CH_SWITCH_NOTIFY",
+ NL80211_CMD_START_P2P_DEVICE: "NL80211_CMD_START_P2P_DEVICE",
+ NL80211_CMD_STOP_P2P_DEVICE: "NL80211_CMD_STOP_P2P_DEVICE",
+ NL80211_CMD_CONN_FAILED: "NL80211_CMD_CONN_FAILED",
+ NL80211_CMD_SET_MCAST_RATE: "NL80211_CMD_SET_MCAST_RATE",
+ NL80211_CMD_SET_MAC_ACL: "NL80211_CMD_SET_MAC_ACL",
+ NL80211_CMD_RADAR_DETECT: "NL80211_CMD_RADAR_DETECT",
+ NL80211_CMD_GET_PROTOCOL_FEATURES: "NL80211_CMD_GET_PROTOCOL_FEATURES",
+ NL80211_CMD_UPDATE_FT_IES: "NL80211_CMD_UPDATE_FT_IES",
+ NL80211_CMD_FT_EVENT: "NL80211_CMD_FT_EVENT",
+ NL80211_CMD_CRIT_PROTOCOL_START: "NL80211_CMD_CRIT_PROTOCOL_START",
+ NL80211_CMD_CRIT_PROTOCOL_STOP: "NL80211_CMD_CRIT_PROTOCOL_STOP",
+ __NL80211_CMD_AFTER_LAST: "__NL80211_CMD_AFTER_LAST",
+}
+nl80211_attrs2str = {
+ NL80211_ATTR_UNSPEC: "NL80211_ATTR_UNSPEC",
+ NL80211_ATTR_WIPHY: "NL80211_ATTR_WIPHY",
+ NL80211_ATTR_WIPHY_NAME: "NL80211_ATTR_WIPHY_NAME",
+ NL80211_ATTR_IFINDEX: "NL80211_ATTR_IFINDEX",
+ NL80211_ATTR_IFNAME: "NL80211_ATTR_IFNAME",
+ NL80211_ATTR_IFTYPE: "NL80211_ATTR_IFTYPE",
+ NL80211_ATTR_MAC: "NL80211_ATTR_MAC",
+ NL80211_ATTR_KEY_DATA: "NL80211_ATTR_KEY_DATA",
+ NL80211_ATTR_KEY_IDX: "NL80211_ATTR_KEY_IDX",
+ NL80211_ATTR_KEY_CIPHER: "NL80211_ATTR_KEY_CIPHER",
+ NL80211_ATTR_KEY_SEQ: "NL80211_ATTR_KEY_SEQ",
+ NL80211_ATTR_KEY_DEFAULT: "NL80211_ATTR_KEY_DEFAULT",
+ NL80211_ATTR_BEACON_INTERVAL: "NL80211_ATTR_BEACON_INTERVAL",
+ NL80211_ATTR_DTIM_PERIOD: "NL80211_ATTR_DTIM_PERIOD",
+ NL80211_ATTR_BEACON_HEAD: "NL80211_ATTR_BEACON_HEAD",
+ NL80211_ATTR_BEACON_TAIL: "NL80211_ATTR_BEACON_TAIL",
+ NL80211_ATTR_STA_AID: "NL80211_ATTR_STA_AID",
+ NL80211_ATTR_STA_FLAGS: "NL80211_ATTR_STA_FLAGS",
+ NL80211_ATTR_STA_LISTEN_INTERVAL: "NL80211_ATTR_STA_LISTEN_INTERVAL",
+ NL80211_ATTR_STA_SUPPORTED_RATES: "NL80211_ATTR_STA_SUPPORTED_RATES",
+ NL80211_ATTR_STA_VLAN: "NL80211_ATTR_STA_VLAN",
+ NL80211_ATTR_STA_INFO: "NL80211_ATTR_STA_INFO",
+ NL80211_ATTR_WIPHY_BANDS: "NL80211_ATTR_WIPHY_BANDS",
+ NL80211_ATTR_MNTR_FLAGS: "NL80211_ATTR_MNTR_FLAGS",
+ NL80211_ATTR_MESH_ID: "NL80211_ATTR_MESH_ID",
+ NL80211_ATTR_STA_PLINK_ACTION: "NL80211_ATTR_STA_PLINK_ACTION",
+ NL80211_ATTR_MPATH_NEXT_HOP: "NL80211_ATTR_MPATH_NEXT_HOP",
+ NL80211_ATTR_MPATH_INFO: "NL80211_ATTR_MPATH_INFO",
+ NL80211_ATTR_BSS_CTS_PROT: "NL80211_ATTR_BSS_CTS_PROT",
+ NL80211_ATTR_BSS_SHORT_PREAMBLE: "NL80211_ATTR_BSS_SHORT_PREAMBLE",
+ NL80211_ATTR_BSS_SHORT_SLOT_TIME: "NL80211_ATTR_BSS_SHORT_SLOT_TIME",
+ NL80211_ATTR_HT_CAPABILITY: "NL80211_ATTR_HT_CAPABILITY",
+ NL80211_ATTR_SUPPORTED_IFTYPES: "NL80211_ATTR_SUPPORTED_IFTYPES",
+ NL80211_ATTR_REG_ALPHA2: "NL80211_ATTR_REG_ALPHA2",
+ NL80211_ATTR_REG_RULES: "NL80211_ATTR_REG_RULES",
+ NL80211_ATTR_MESH_CONFIG: "NL80211_ATTR_MESH_CONFIG",
+ NL80211_ATTR_BSS_BASIC_RATES: "NL80211_ATTR_BSS_BASIC_RATES",
+ NL80211_ATTR_WIPHY_TXQ_PARAMS: "NL80211_ATTR_WIPHY_TXQ_PARAMS",
+ NL80211_ATTR_WIPHY_FREQ: "NL80211_ATTR_WIPHY_FREQ",
+ NL80211_ATTR_WIPHY_CHANNEL_TYPE: "NL80211_ATTR_WIPHY_CHANNEL_TYPE",
+ NL80211_ATTR_KEY_DEFAULT_MGMT: "NL80211_ATTR_KEY_DEFAULT_MGMT",
+ NL80211_ATTR_MGMT_SUBTYPE: "NL80211_ATTR_MGMT_SUBTYPE",
+ NL80211_ATTR_IE: "NL80211_ATTR_IE",
+ NL80211_ATTR_MAX_NUM_SCAN_SSIDS: "NL80211_ATTR_MAX_NUM_SCAN_SSIDS",
+ NL80211_ATTR_SCAN_FREQUENCIES: "NL80211_ATTR_SCAN_FREQUENCIES",
+ NL80211_ATTR_SCAN_SSIDS: "NL80211_ATTR_SCAN_SSIDS",
+ NL80211_ATTR_GENERATION: "NL80211_ATTR_GENERATION",
+ NL80211_ATTR_BSS: "NL80211_ATTR_BSS",
+ NL80211_ATTR_REG_INITIATOR: "NL80211_ATTR_REG_INITIATOR",
+ NL80211_ATTR_REG_TYPE: "NL80211_ATTR_REG_TYPE",
+ NL80211_ATTR_SUPPORTED_COMMANDS: "NL80211_ATTR_SUPPORTED_COMMANDS",
+ NL80211_ATTR_FRAME: "NL80211_ATTR_FRAME",
+ NL80211_ATTR_SSID: "NL80211_ATTR_SSID",
+ NL80211_ATTR_AUTH_TYPE: "NL80211_ATTR_AUTH_TYPE",
+ NL80211_ATTR_REASON_CODE: "NL80211_ATTR_REASON_CODE",
+ NL80211_ATTR_KEY_TYPE: "NL80211_ATTR_KEY_TYPE",
+ NL80211_ATTR_MAX_SCAN_IE_LEN: "NL80211_ATTR_MAX_SCAN_IE_LEN",
+ NL80211_ATTR_CIPHER_SUITES: "NL80211_ATTR_CIPHER_SUITES",
+ NL80211_ATTR_FREQ_BEFORE: "NL80211_ATTR_FREQ_BEFORE",
+ NL80211_ATTR_FREQ_AFTER: "NL80211_ATTR_FREQ_AFTER",
+ NL80211_ATTR_FREQ_FIXED: "NL80211_ATTR_FREQ_FIXED",
+ NL80211_ATTR_WIPHY_RETRY_SHORT: "NL80211_ATTR_WIPHY_RETRY_SHORT",
+ NL80211_ATTR_WIPHY_RETRY_LONG: "NL80211_ATTR_WIPHY_RETRY_LONG",
+ NL80211_ATTR_WIPHY_FRAG_THRESHOLD: "NL80211_ATTR_WIPHY_FRAG_THRESHOLD",
+ NL80211_ATTR_WIPHY_RTS_THRESHOLD: "NL80211_ATTR_WIPHY_RTS_THRESHOLD",
+ NL80211_ATTR_TIMED_OUT: "NL80211_ATTR_TIMED_OUT",
+ NL80211_ATTR_USE_MFP: "NL80211_ATTR_USE_MFP",
+ NL80211_ATTR_STA_FLAGS2: "NL80211_ATTR_STA_FLAGS2",
+ NL80211_ATTR_CONTROL_PORT: "NL80211_ATTR_CONTROL_PORT",
+ NL80211_ATTR_TESTDATA: "NL80211_ATTR_TESTDATA",
+ NL80211_ATTR_PRIVACY: "NL80211_ATTR_PRIVACY",
+ NL80211_ATTR_DISCONNECTED_BY_AP: "NL80211_ATTR_DISCONNECTED_BY_AP",
+ NL80211_ATTR_STATUS_CODE: "NL80211_ATTR_STATUS_CODE",
+ NL80211_ATTR_CIPHER_SUITES_PAIRWISE: "NL80211_ATTR_CIPHER_SUITES_PAIRWISE",
+ NL80211_ATTR_CIPHER_SUITE_GROUP: "NL80211_ATTR_CIPHER_SUITE_GROUP",
+ NL80211_ATTR_WPA_VERSIONS: "NL80211_ATTR_WPA_VERSIONS",
+ NL80211_ATTR_AKM_SUITES: "NL80211_ATTR_AKM_SUITES",
+ NL80211_ATTR_REQ_IE: "NL80211_ATTR_REQ_IE",
+ NL80211_ATTR_RESP_IE: "NL80211_ATTR_RESP_IE",
+ NL80211_ATTR_PREV_BSSID: "NL80211_ATTR_PREV_BSSID",
+ NL80211_ATTR_KEY: "NL80211_ATTR_KEY",
+ NL80211_ATTR_KEYS: "NL80211_ATTR_KEYS",
+ NL80211_ATTR_PID: "NL80211_ATTR_PID",
+ NL80211_ATTR_4ADDR: "NL80211_ATTR_4ADDR",
+ NL80211_ATTR_SURVEY_INFO: "NL80211_ATTR_SURVEY_INFO",
+ NL80211_ATTR_PMKID: "NL80211_ATTR_PMKID",
+ NL80211_ATTR_MAX_NUM_PMKIDS: "NL80211_ATTR_MAX_NUM_PMKIDS",
+ NL80211_ATTR_DURATION: "NL80211_ATTR_DURATION",
+ NL80211_ATTR_COOKIE: "NL80211_ATTR_COOKIE",
+ NL80211_ATTR_WIPHY_COVERAGE_CLASS: "NL80211_ATTR_WIPHY_COVERAGE_CLASS",
+ NL80211_ATTR_TX_RATES: "NL80211_ATTR_TX_RATES",
+ NL80211_ATTR_FRAME_MATCH: "NL80211_ATTR_FRAME_MATCH",
+ NL80211_ATTR_ACK: "NL80211_ATTR_ACK",
+ NL80211_ATTR_PS_STATE: "NL80211_ATTR_PS_STATE",
+ NL80211_ATTR_CQM: "NL80211_ATTR_CQM",
+ NL80211_ATTR_LOCAL_STATE_CHANGE: "NL80211_ATTR_LOCAL_STATE_CHANGE",
+ NL80211_ATTR_AP_ISOLATE: "NL80211_ATTR_AP_ISOLATE",
+ NL80211_ATTR_WIPHY_TX_POWER_SETTING: "NL80211_ATTR_WIPHY_TX_POWER_SETTING",
+ NL80211_ATTR_WIPHY_TX_POWER_LEVEL: "NL80211_ATTR_WIPHY_TX_POWER_LEVEL",
+ NL80211_ATTR_TX_FRAME_TYPES: "NL80211_ATTR_TX_FRAME_TYPES",
+ NL80211_ATTR_RX_FRAME_TYPES: "NL80211_ATTR_RX_FRAME_TYPES",
+ NL80211_ATTR_FRAME_TYPE: "NL80211_ATTR_FRAME_TYPE",
+ NL80211_ATTR_CONTROL_PORT_ETHERTYPE: "NL80211_ATTR_CONTROL_PORT_ETHERTYPE",
+ NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT: "NL80211_ATTR_CONTROL_PORT_NO_ENCRYPT",
+ NL80211_ATTR_SUPPORT_IBSS_RSN: "NL80211_ATTR_SUPPORT_IBSS_RSN",
+ NL80211_ATTR_WIPHY_ANTENNA_TX: "NL80211_ATTR_WIPHY_ANTENNA_TX",
+ NL80211_ATTR_WIPHY_ANTENNA_RX: "NL80211_ATTR_WIPHY_ANTENNA_RX",
+ NL80211_ATTR_MCAST_RATE: "NL80211_ATTR_MCAST_RATE",
+ NL80211_ATTR_OFFCHANNEL_TX_OK: "NL80211_ATTR_OFFCHANNEL_TX_OK",
+ NL80211_ATTR_BSS_HT_OPMODE: "NL80211_ATTR_BSS_HT_OPMODE",
+ NL80211_ATTR_KEY_DEFAULT_TYPES: "NL80211_ATTR_KEY_DEFAULT_TYPES",
+ NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION: "NL80211_ATTR_MAX_REMAIN_ON_CHANNEL_DURATION",
+ NL80211_ATTR_MESH_SETUP: "NL80211_ATTR_MESH_SETUP",
+ NL80211_ATTR_WIPHY_ANTENNA_AVAIL_TX: "NL80211_ATTR_WIPHY_ANTENNA_AVAIL_TX",
+ NL80211_ATTR_WIPHY_ANTENNA_AVAIL_RX: "NL80211_ATTR_WIPHY_ANTENNA_AVAIL_RX",
+ NL80211_ATTR_SUPPORT_MESH_AUTH: "NL80211_ATTR_SUPPORT_MESH_AUTH",
+ NL80211_ATTR_STA_PLINK_STATE: "NL80211_ATTR_STA_PLINK_STATE",
+ NL80211_ATTR_WOWLAN_TRIGGERS: "NL80211_ATTR_WOWLAN_TRIGGERS",
+ NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED: "NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED",
+ NL80211_ATTR_SCHED_SCAN_INTERVAL: "NL80211_ATTR_SCHED_SCAN_INTERVAL",
+ NL80211_ATTR_INTERFACE_COMBINATIONS: "NL80211_ATTR_INTERFACE_COMBINATIONS",
+ NL80211_ATTR_SOFTWARE_IFTYPES: "NL80211_ATTR_SOFTWARE_IFTYPES",
+ NL80211_ATTR_REKEY_DATA: "NL80211_ATTR_REKEY_DATA",
+ NL80211_ATTR_MAX_NUM_SCHED_SCAN_SSIDS: "NL80211_ATTR_MAX_NUM_SCHED_SCAN_SSIDS",
+ NL80211_ATTR_MAX_SCHED_SCAN_IE_LEN: "NL80211_ATTR_MAX_SCHED_SCAN_IE_LEN",
+ NL80211_ATTR_SCAN_SUPP_RATES: "NL80211_ATTR_SCAN_SUPP_RATES",
+ NL80211_ATTR_HIDDEN_SSID: "NL80211_ATTR_HIDDEN_SSID",
+ NL80211_ATTR_IE_PROBE_RESP: "NL80211_ATTR_IE_PROBE_RESP",
+ NL80211_ATTR_IE_ASSOC_RESP: "NL80211_ATTR_IE_ASSOC_RESP",
+ NL80211_ATTR_STA_WME: "NL80211_ATTR_STA_WME",
+ NL80211_ATTR_SUPPORT_AP_UAPSD: "NL80211_ATTR_SUPPORT_AP_UAPSD",
+ NL80211_ATTR_ROAM_SUPPORT: "NL80211_ATTR_ROAM_SUPPORT",
+ NL80211_ATTR_SCHED_SCAN_MATCH: "NL80211_ATTR_SCHED_SCAN_MATCH",
+ NL80211_ATTR_MAX_MATCH_SETS: "NL80211_ATTR_MAX_MATCH_SETS",
+ NL80211_ATTR_PMKSA_CANDIDATE: "NL80211_ATTR_PMKSA_CANDIDATE",
+ NL80211_ATTR_TX_NO_CCK_RATE: "NL80211_ATTR_TX_NO_CCK_RATE",
+ NL80211_ATTR_TDLS_ACTION: "NL80211_ATTR_TDLS_ACTION",
+ NL80211_ATTR_TDLS_DIALOG_TOKEN: "NL80211_ATTR_TDLS_DIALOG_TOKEN",
+ NL80211_ATTR_TDLS_OPERATION: "NL80211_ATTR_TDLS_OPERATION",
+ NL80211_ATTR_TDLS_SUPPORT: "NL80211_ATTR_TDLS_SUPPORT",
+ NL80211_ATTR_TDLS_EXTERNAL_SETUP: "NL80211_ATTR_TDLS_EXTERNAL_SETUP",
+ NL80211_ATTR_DEVICE_AP_SME: "NL80211_ATTR_DEVICE_AP_SME",
+ NL80211_ATTR_DONT_WAIT_FOR_ACK: "NL80211_ATTR_DONT_WAIT_FOR_ACK",
+ NL80211_ATTR_FEATURE_FLAGS: "NL80211_ATTR_FEATURE_FLAGS",
+ NL80211_ATTR_PROBE_RESP_OFFLOAD: "NL80211_ATTR_PROBE_RESP_OFFLOAD",
+ NL80211_ATTR_PROBE_RESP: "NL80211_ATTR_PROBE_RESP",
+ NL80211_ATTR_DFS_REGION: "NL80211_ATTR_DFS_REGION",
+ NL80211_ATTR_DISABLE_HT: "NL80211_ATTR_DISABLE_HT",
+ NL80211_ATTR_HT_CAPABILITY_MASK: "NL80211_ATTR_HT_CAPABILITY_MASK",
+ NL80211_ATTR_NOACK_MAP: "NL80211_ATTR_NOACK_MAP",
+ NL80211_ATTR_INACTIVITY_TIMEOUT: "NL80211_ATTR_INACTIVITY_TIMEOUT",
+ NL80211_ATTR_RX_SIGNAL_DBM: "NL80211_ATTR_RX_SIGNAL_DBM",
+ NL80211_ATTR_BG_SCAN_PERIOD: "NL80211_ATTR_BG_SCAN_PERIOD",
+ NL80211_ATTR_WDEV: "NL80211_ATTR_WDEV",
+ NL80211_ATTR_USER_REG_HINT_TYPE: "NL80211_ATTR_USER_REG_HINT_TYPE",
+ NL80211_ATTR_CONN_FAILED_REASON: "NL80211_ATTR_CONN_FAILED_REASON",
+ NL80211_ATTR_SAE_DATA: "NL80211_ATTR_SAE_DATA",
+ NL80211_ATTR_VHT_CAPABILITY: "NL80211_ATTR_VHT_CAPABILITY",
+ NL80211_ATTR_SCAN_FLAGS: "NL80211_ATTR_SCAN_FLAGS",
+ NL80211_ATTR_CHANNEL_WIDTH: "NL80211_ATTR_CHANNEL_WIDTH",
+ NL80211_ATTR_CENTER_FREQ1: "NL80211_ATTR_CENTER_FREQ1",
+ NL80211_ATTR_CENTER_FREQ2: "NL80211_ATTR_CENTER_FREQ2",
+ NL80211_ATTR_P2P_CTWINDOW: "NL80211_ATTR_P2P_CTWINDOW",
+ NL80211_ATTR_P2P_OPPPS: "NL80211_ATTR_P2P_OPPPS",
+ NL80211_ATTR_LOCAL_MESH_POWER_MODE: "NL80211_ATTR_LOCAL_MESH_POWER_MODE",
+ NL80211_ATTR_ACL_POLICY: "NL80211_ATTR_ACL_POLICY",
+ NL80211_ATTR_MAC_ADDRS: "NL80211_ATTR_MAC_ADDRS",
+ NL80211_ATTR_MAC_ACL_MAX: "NL80211_ATTR_MAC_ACL_MAX",
+ NL80211_ATTR_RADAR_EVENT: "NL80211_ATTR_RADAR_EVENT",
+ NL80211_ATTR_EXT_CAPA: "NL80211_ATTR_EXT_CAPA",
+ NL80211_ATTR_EXT_CAPA_MASK: "NL80211_ATTR_EXT_CAPA_MASK",
+ NL80211_ATTR_STA_CAPABILITY: "NL80211_ATTR_STA_CAPABILITY",
+ NL80211_ATTR_STA_EXT_CAPABILITY: "NL80211_ATTR_STA_EXT_CAPABILITY",
+ NL80211_ATTR_PROTOCOL_FEATURES: "NL80211_ATTR_PROTOCOL_FEATURES",
+ NL80211_ATTR_SPLIT_WIPHY_DUMP: "NL80211_ATTR_SPLIT_WIPHY_DUMP",
+ NL80211_ATTR_DISABLE_VHT: "NL80211_ATTR_DISABLE_VHT",
+ NL80211_ATTR_VHT_CAPABILITY_MASK: "NL80211_ATTR_VHT_CAPABILITY_MASK",
+ NL80211_ATTR_MDID: "NL80211_ATTR_MDID",
+ NL80211_ATTR_IE_RIC: "NL80211_ATTR_IE_RIC",
+ NL80211_ATTR_CRIT_PROT_ID: "NL80211_ATTR_CRIT_PROT_ID",
+ NL80211_ATTR_MAX_CRIT_PROT_DURATION: "NL80211_ATTR_MAX_CRIT_PROT_DURATION",
+ NL80211_ATTR_PEER_AID: "NL80211_ATTR_PEER_AID",
+ __NL80211_ATTR_AFTER_LAST: "__NL80211_ATTR_AFTER_LAST",
+}
+nl80211_iftype2str = {
+ NL80211_IFTYPE_UNSPECIFIED: "NL80211_IFTYPE_UNSPECIFIED",
+ NL80211_IFTYPE_ADHOC: "NL80211_IFTYPE_ADHOC",
+ NL80211_IFTYPE_STATION: "NL80211_IFTYPE_STATION",
+ NL80211_IFTYPE_AP: "NL80211_IFTYPE_AP",
+ NL80211_IFTYPE_AP_VLAN: "NL80211_IFTYPE_AP_VLAN",
+ NL80211_IFTYPE_WDS: "NL80211_IFTYPE_WDS",
+ NL80211_IFTYPE_MONITOR: "NL80211_IFTYPE_MONITOR",
+ NL80211_IFTYPE_MESH_POINT: "NL80211_IFTYPE_MESH_POINT",
+ NL80211_IFTYPE_P2P_CLIENT: "NL80211_IFTYPE_P2P_CLIENT",
+ NL80211_IFTYPE_P2P_GO: "NL80211_IFTYPE_P2P_GO",
+ NL80211_IFTYPE_P2P_DEVICE: "NL80211_IFTYPE_P2P_DEVICE",
+ NUM_NL80211_IFTYPES: "NUM_NL80211_IFTYPES",
+}
+nl80211_sta_flags2str = {
+ __NL80211_STA_FLAG_INVALID: "__NL80211_STA_FLAG_INVALID",
+ NL80211_STA_FLAG_AUTHORIZED: "NL80211_STA_FLAG_AUTHORIZED",
+ NL80211_STA_FLAG_SHORT_PREAMBLE: "NL80211_STA_FLAG_SHORT_PREAMBLE",
+ NL80211_STA_FLAG_WME: "NL80211_STA_FLAG_WME",
+ NL80211_STA_FLAG_MFP: "NL80211_STA_FLAG_MFP",
+ NL80211_STA_FLAG_AUTHENTICATED: "NL80211_STA_FLAG_AUTHENTICATED",
+ NL80211_STA_FLAG_TDLS_PEER: "NL80211_STA_FLAG_TDLS_PEER",
+ NL80211_STA_FLAG_ASSOCIATED: "NL80211_STA_FLAG_ASSOCIATED",
+ __NL80211_STA_FLAG_AFTER_LAST: "__NL80211_STA_FLAG_AFTER_LAST",
+}
+nl80211_rate_info2str = {
+ __NL80211_RATE_INFO_INVALID: "__NL80211_RATE_INFO_INVALID",
+ NL80211_RATE_INFO_BITRATE: "NL80211_RATE_INFO_BITRATE",
+ NL80211_RATE_INFO_MCS: "NL80211_RATE_INFO_MCS",
+ NL80211_RATE_INFO_40_MHZ_WIDTH: "NL80211_RATE_INFO_40_MHZ_WIDTH",
+ NL80211_RATE_INFO_SHORT_GI: "NL80211_RATE_INFO_SHORT_GI",
+ NL80211_RATE_INFO_BITRATE32: "NL80211_RATE_INFO_BITRATE32",
+ NL80211_RATE_INFO_VHT_MCS: "NL80211_RATE_INFO_VHT_MCS",
+ NL80211_RATE_INFO_VHT_NSS: "NL80211_RATE_INFO_VHT_NSS",
+ NL80211_RATE_INFO_80_MHZ_WIDTH: "NL80211_RATE_INFO_80_MHZ_WIDTH",
+ NL80211_RATE_INFO_80P80_MHZ_WIDTH: "NL80211_RATE_INFO_80P80_MHZ_WIDTH",
+ NL80211_RATE_INFO_160_MHZ_WIDTH: "NL80211_RATE_INFO_160_MHZ_WIDTH",
+ __NL80211_RATE_INFO_AFTER_LAST: "__NL80211_RATE_INFO_AFTER_LAST",
+}
+nl80211_sta_bss_param2str = {
+ __NL80211_STA_BSS_PARAM_INVALID: "__NL80211_STA_BSS_PARAM_INVALID",
+ NL80211_STA_BSS_PARAM_CTS_PROT: "NL80211_STA_BSS_PARAM_CTS_PROT",
+ NL80211_STA_BSS_PARAM_SHORT_PREAMBLE: "NL80211_STA_BSS_PARAM_SHORT_PREAMBLE",
+ NL80211_STA_BSS_PARAM_SHORT_SLOT_TIME: "NL80211_STA_BSS_PARAM_SHORT_SLOT_TIME",
+ NL80211_STA_BSS_PARAM_DTIM_PERIOD: "NL80211_STA_BSS_PARAM_DTIM_PERIOD",
+ NL80211_STA_BSS_PARAM_BEACON_INTERVAL: "NL80211_STA_BSS_PARAM_BEACON_INTERVAL",
+ __NL80211_STA_BSS_PARAM_AFTER_LAST: "__NL80211_STA_BSS_PARAM_AFTER_LAST",
+}
+nl80211_sta_info2str = {
+ __NL80211_STA_INFO_INVALID: "__NL80211_STA_INFO_INVALID",
+ NL80211_STA_INFO_INACTIVE_TIME: "NL80211_STA_INFO_INACTIVE_TIME",
+ NL80211_STA_INFO_RX_BYTES: "NL80211_STA_INFO_RX_BYTES",
+ NL80211_STA_INFO_TX_BYTES: "NL80211_STA_INFO_TX_BYTES",
+ NL80211_STA_INFO_LLID: "NL80211_STA_INFO_LLID",
+ NL80211_STA_INFO_PLID: "NL80211_STA_INFO_PLID",
+ NL80211_STA_INFO_PLINK_STATE: "NL80211_STA_INFO_PLINK_STATE",
+ NL80211_STA_INFO_SIGNAL: "NL80211_STA_INFO_SIGNAL",
+ NL80211_STA_INFO_TX_BITRATE: "NL80211_STA_INFO_TX_BITRATE",
+ NL80211_STA_INFO_RX_PACKETS: "NL80211_STA_INFO_RX_PACKETS",
+ NL80211_STA_INFO_TX_PACKETS: "NL80211_STA_INFO_TX_PACKETS",
+ NL80211_STA_INFO_TX_RETRIES: "NL80211_STA_INFO_TX_RETRIES",
+ NL80211_STA_INFO_TX_FAILED: "NL80211_STA_INFO_TX_FAILED",
+ NL80211_STA_INFO_SIGNAL_AVG: "NL80211_STA_INFO_SIGNAL_AVG",
+ NL80211_STA_INFO_RX_BITRATE: "NL80211_STA_INFO_RX_BITRATE",
+ NL80211_STA_INFO_BSS_PARAM: "NL80211_STA_INFO_BSS_PARAM",
+ NL80211_STA_INFO_CONNECTED_TIME: "NL80211_STA_INFO_CONNECTED_TIME",
+ NL80211_STA_INFO_STA_FLAGS: "NL80211_STA_INFO_STA_FLAGS",
+ NL80211_STA_INFO_BEACON_LOSS: "NL80211_STA_INFO_BEACON_LOSS",
+ NL80211_STA_INFO_T_OFFSET: "NL80211_STA_INFO_T_OFFSET",
+ NL80211_STA_INFO_LOCAL_PM: "NL80211_STA_INFO_LOCAL_PM",
+ NL80211_STA_INFO_PEER_PM: "NL80211_STA_INFO_PEER_PM",
+ NL80211_STA_INFO_NONPEER_PM: "NL80211_STA_INFO_NONPEER_PM",
+ NL80211_STA_INFO_RX_BYTES64: "NL80211_STA_INFO_RX_BYTES64",
+ NL80211_STA_INFO_TX_BYTES64: "NL80211_STA_INFO_TX_BYTES64",
+ NL80211_STA_INFO_CHAIN_SIGNAL: "NL80211_STA_INFO_CHAIN_SIGNAL",
+ NL80211_STA_INFO_CHAIN_SIGNAL_AVG: "NL80211_STA_INFO_CHAIN_SIGNAL_AVG",
+ __NL80211_STA_INFO_AFTER_LAST: "__NL80211_STA_INFO_AFTER_LAST",
+}
+nl80211_mpath_flags2str = {
+ NL80211_MPATH_FLAG_ACTIVE: "NL80211_MPATH_FLAG_ACTIVE",
+ NL80211_MPATH_FLAG_RESOLVING: "NL80211_MPATH_FLAG_RESOLVING",
+ NL80211_MPATH_FLAG_SN_VALID: "NL80211_MPATH_FLAG_SN_VALID",
+ NL80211_MPATH_FLAG_FIXED: "NL80211_MPATH_FLAG_FIXED",
+ NL80211_MPATH_FLAG_RESOLVED: "NL80211_MPATH_FLAG_RESOLVED",
+}
+nl80211_mpath_info2str = {
+ __NL80211_MPATH_INFO_INVALID: "__NL80211_MPATH_INFO_INVALID",
+ NL80211_MPATH_INFO_FRAME_QLEN: "NL80211_MPATH_INFO_FRAME_QLEN",
+ NL80211_MPATH_INFO_SN: "NL80211_MPATH_INFO_SN",
+ NL80211_MPATH_INFO_METRIC: "NL80211_MPATH_INFO_METRIC",
+ NL80211_MPATH_INFO_EXPTIME: "NL80211_MPATH_INFO_EXPTIME",
+ NL80211_MPATH_INFO_FLAGS: "NL80211_MPATH_INFO_FLAGS",
+ NL80211_MPATH_INFO_DISCOVERY_TIMEOUT: "NL80211_MPATH_INFO_DISCOVERY_TIMEOUT",
+ NL80211_MPATH_INFO_DISCOVERY_RETRIES: "NL80211_MPATH_INFO_DISCOVERY_RETRIES",
+ __NL80211_MPATH_INFO_AFTER_LAST: "__NL80211_MPATH_INFO_AFTER_LAST",
+}
+nl80211_band_attr2str = {
+ __NL80211_BAND_ATTR_INVALID: "__NL80211_BAND_ATTR_INVALID",
+ NL80211_BAND_ATTR_FREQS: "NL80211_BAND_ATTR_FREQS",
+ NL80211_BAND_ATTR_RATES: "NL80211_BAND_ATTR_RATES",
+ NL80211_BAND_ATTR_HT_MCS_SET: "NL80211_BAND_ATTR_HT_MCS_SET",
+ NL80211_BAND_ATTR_HT_CAPA: "NL80211_BAND_ATTR_HT_CAPA",
+ NL80211_BAND_ATTR_HT_AMPDU_FACTOR: "NL80211_BAND_ATTR_HT_AMPDU_FACTOR",
+ NL80211_BAND_ATTR_HT_AMPDU_DENSITY: "NL80211_BAND_ATTR_HT_AMPDU_DENSITY",
+ NL80211_BAND_ATTR_VHT_MCS_SET: "NL80211_BAND_ATTR_VHT_MCS_SET",
+ NL80211_BAND_ATTR_VHT_CAPA: "NL80211_BAND_ATTR_VHT_CAPA",
+ __NL80211_BAND_ATTR_AFTER_LAST: "__NL80211_BAND_ATTR_AFTER_LAST",
+}
+nl80211_frequency_attr2str = {
+ __NL80211_FREQUENCY_ATTR_INVALID: "__NL80211_FREQUENCY_ATTR_INVALID",
+ NL80211_FREQUENCY_ATTR_FREQ: "NL80211_FREQUENCY_ATTR_FREQ",
+ NL80211_FREQUENCY_ATTR_DISABLED: "NL80211_FREQUENCY_ATTR_DISABLED",
+ NL80211_FREQUENCY_ATTR_PASSIVE_SCAN: "NL80211_FREQUENCY_ATTR_PASSIVE_SCAN",
+ NL80211_FREQUENCY_ATTR_NO_IBSS: "NL80211_FREQUENCY_ATTR_NO_IBSS",
+ NL80211_FREQUENCY_ATTR_RADAR: "NL80211_FREQUENCY_ATTR_RADAR",
+ NL80211_FREQUENCY_ATTR_MAX_TX_POWER: "NL80211_FREQUENCY_ATTR_MAX_TX_POWER",
+ NL80211_FREQUENCY_ATTR_DFS_STATE: "NL80211_FREQUENCY_ATTR_DFS_STATE",
+ NL80211_FREQUENCY_ATTR_DFS_TIME: "NL80211_FREQUENCY_ATTR_DFS_TIME",
+ NL80211_FREQUENCY_ATTR_NO_HT40_MINUS: "NL80211_FREQUENCY_ATTR_NO_HT40_MINUS",
+ NL80211_FREQUENCY_ATTR_NO_HT40_PLUS: "NL80211_FREQUENCY_ATTR_NO_HT40_PLUS",
+ NL80211_FREQUENCY_ATTR_NO_80MHZ: "NL80211_FREQUENCY_ATTR_NO_80MHZ",
+ NL80211_FREQUENCY_ATTR_NO_160MHZ: "NL80211_FREQUENCY_ATTR_NO_160MHZ",
+ __NL80211_FREQUENCY_ATTR_AFTER_LAST: "__NL80211_FREQUENCY_ATTR_AFTER_LAST",
+}
+nl80211_bitrate_attr2str = {
+ __NL80211_BITRATE_ATTR_INVALID: "__NL80211_BITRATE_ATTR_INVALID",
+ NL80211_BITRATE_ATTR_RATE: "NL80211_BITRATE_ATTR_RATE",
+ NL80211_BITRATE_ATTR_2GHZ_SHORTPREAMBLE: "NL80211_BITRATE_ATTR_2GHZ_SHORTPREAMBLE",
+ __NL80211_BITRATE_ATTR_AFTER_LAST: "__NL80211_BITRATE_ATTR_AFTER_LAST",
+}
+nl80211_reg_initiator2str = {
+ NL80211_REGDOM_SET_BY_CORE: "NL80211_REGDOM_SET_BY_CORE",
+ NL80211_REGDOM_SET_BY_USER: "NL80211_REGDOM_SET_BY_USER",
+ NL80211_REGDOM_SET_BY_DRIVER: "NL80211_REGDOM_SET_BY_DRIVER",
+ NL80211_REGDOM_SET_BY_COUNTRY_IE: "NL80211_REGDOM_SET_BY_COUNTRY_IE",
+}
+nl80211_reg_type2str = {
+ NL80211_REGDOM_TYPE_COUNTRY: "NL80211_REGDOM_TYPE_COUNTRY",
+ NL80211_REGDOM_TYPE_WORLD: "NL80211_REGDOM_TYPE_WORLD",
+ NL80211_REGDOM_TYPE_CUSTOM_WORLD: "NL80211_REGDOM_TYPE_CUSTOM_WORLD",
+ NL80211_REGDOM_TYPE_INTERSECTION: "NL80211_REGDOM_TYPE_INTERSECTION",
+}
+nl80211_reg_rule_attr2str = {
+ __NL80211_REG_RULE_ATTR_INVALID: "__NL80211_REG_RULE_ATTR_INVALID",
+ NL80211_ATTR_REG_RULE_FLAGS: "NL80211_ATTR_REG_RULE_FLAGS",
+ NL80211_ATTR_FREQ_RANGE_START: "NL80211_ATTR_FREQ_RANGE_START",
+ NL80211_ATTR_FREQ_RANGE_END: "NL80211_ATTR_FREQ_RANGE_END",
+ NL80211_ATTR_FREQ_RANGE_MAX_BW: "NL80211_ATTR_FREQ_RANGE_MAX_BW",
+ NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN: "NL80211_ATTR_POWER_RULE_MAX_ANT_GAIN",
+ NL80211_ATTR_POWER_RULE_MAX_EIRP: "NL80211_ATTR_POWER_RULE_MAX_EIRP",
+ __NL80211_REG_RULE_ATTR_AFTER_LAST: "__NL80211_REG_RULE_ATTR_AFTER_LAST",
+}
+nl80211_sched_scan_match_attr2str = {
+ __NL80211_SCHED_SCAN_MATCH_ATTR_INVALID: "__NL80211_SCHED_SCAN_MATCH_ATTR_INVALID",
+ NL80211_SCHED_SCAN_MATCH_ATTR_SSID: "NL80211_SCHED_SCAN_MATCH_ATTR_SSID",
+ NL80211_SCHED_SCAN_MATCH_ATTR_RSSI: "NL80211_SCHED_SCAN_MATCH_ATTR_RSSI",
+ __NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST: "__NL80211_SCHED_SCAN_MATCH_ATTR_AFTER_LAST",
+}
+nl80211_reg_rule_flags2str = {
+ NL80211_RRF_NO_OFDM: "NL80211_RRF_NO_OFDM",
+ NL80211_RRF_NO_CCK: "NL80211_RRF_NO_CCK",
+ NL80211_RRF_NO_INDOOR: "NL80211_RRF_NO_INDOOR",
+ NL80211_RRF_NO_OUTDOOR: "NL80211_RRF_NO_OUTDOOR",
+ NL80211_RRF_DFS: "NL80211_RRF_DFS",
+ NL80211_RRF_PTP_ONLY: "NL80211_RRF_PTP_ONLY",
+ NL80211_RRF_PTMP_ONLY: "NL80211_RRF_PTMP_ONLY",
+ NL80211_RRF_PASSIVE_SCAN: "NL80211_RRF_PASSIVE_SCAN",
+ NL80211_RRF_NO_IBSS: "NL80211_RRF_NO_IBSS",
+}
+nl80211_dfs_regions2str = {
+}
+nl80211_user_reg_hint_type2str = {
+}
+nl80211_survey_info2str = {
+ __NL80211_SURVEY_INFO_INVALID: "__NL80211_SURVEY_INFO_INVALID",
+ NL80211_SURVEY_INFO_FREQUENCY: "NL80211_SURVEY_INFO_FREQUENCY",
+ NL80211_SURVEY_INFO_NOISE: "NL80211_SURVEY_INFO_NOISE",
+ NL80211_SURVEY_INFO_IN_USE: "NL80211_SURVEY_INFO_IN_USE",
+ NL80211_SURVEY_INFO_CHANNEL_TIME: "NL80211_SURVEY_INFO_CHANNEL_TIME",
+ NL80211_SURVEY_INFO_CHANNEL_TIME_BUSY: "NL80211_SURVEY_INFO_CHANNEL_TIME_BUSY",
+ NL80211_SURVEY_INFO_CHANNEL_TIME_EXT_BUSY: "NL80211_SURVEY_INFO_CHANNEL_TIME_EXT_BUSY",
+ NL80211_SURVEY_INFO_CHANNEL_TIME_RX: "NL80211_SURVEY_INFO_CHANNEL_TIME_RX",
+ NL80211_SURVEY_INFO_CHANNEL_TIME_TX: "NL80211_SURVEY_INFO_CHANNEL_TIME_TX",
+ __NL80211_SURVEY_INFO_AFTER_LAST: "__NL80211_SURVEY_INFO_AFTER_LAST",
+}
+nl80211_mntr_flags2str = {
+ __NL80211_MNTR_FLAG_INVALID: "__NL80211_MNTR_FLAG_INVALID",
+ NL80211_MNTR_FLAG_FCSFAIL: "NL80211_MNTR_FLAG_FCSFAIL",
+ NL80211_MNTR_FLAG_PLCPFAIL: "NL80211_MNTR_FLAG_PLCPFAIL",
+ NL80211_MNTR_FLAG_CONTROL: "NL80211_MNTR_FLAG_CONTROL",
+ NL80211_MNTR_FLAG_OTHER_BSS: "NL80211_MNTR_FLAG_OTHER_BSS",
+ NL80211_MNTR_FLAG_COOK_FRAMES: "NL80211_MNTR_FLAG_COOK_FRAMES",
+ NL80211_MNTR_FLAG_ACTIVE: "NL80211_MNTR_FLAG_ACTIVE",
+ __NL80211_MNTR_FLAG_AFTER_LAST: "__NL80211_MNTR_FLAG_AFTER_LAST",
+}
+nl80211_mesh_power_mode2str = {
+ NL80211_MESH_POWER_UNKNOWN: "NL80211_MESH_POWER_UNKNOWN",
+ NL80211_MESH_POWER_ACTIVE: "NL80211_MESH_POWER_ACTIVE",
+ NL80211_MESH_POWER_LIGHT_SLEEP: "NL80211_MESH_POWER_LIGHT_SLEEP",
+ NL80211_MESH_POWER_DEEP_SLEEP: "NL80211_MESH_POWER_DEEP_SLEEP",
+ __NL80211_MESH_POWER_AFTER_LAST: "__NL80211_MESH_POWER_AFTER_LAST",
+}
+nl80211_meshconf_params2str = {
+ __NL80211_MESHCONF_INVALID: "__NL80211_MESHCONF_INVALID",
+ NL80211_MESHCONF_RETRY_TIMEOUT: "NL80211_MESHCONF_RETRY_TIMEOUT",
+ NL80211_MESHCONF_CONFIRM_TIMEOUT: "NL80211_MESHCONF_CONFIRM_TIMEOUT",
+ NL80211_MESHCONF_HOLDING_TIMEOUT: "NL80211_MESHCONF_HOLDING_TIMEOUT",
+ NL80211_MESHCONF_MAX_PEER_LINKS: "NL80211_MESHCONF_MAX_PEER_LINKS",
+ NL80211_MESHCONF_MAX_RETRIES: "NL80211_MESHCONF_MAX_RETRIES",
+ NL80211_MESHCONF_TTL: "NL80211_MESHCONF_TTL",
+ NL80211_MESHCONF_AUTO_OPEN_PLINKS: "NL80211_MESHCONF_AUTO_OPEN_PLINKS",
+ NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES: "NL80211_MESHCONF_HWMP_MAX_PREQ_RETRIES",
+ NL80211_MESHCONF_PATH_REFRESH_TIME: "NL80211_MESHCONF_PATH_REFRESH_TIME",
+ NL80211_MESHCONF_MIN_DISCOVERY_TIMEOUT: "NL80211_MESHCONF_MIN_DISCOVERY_TIMEOUT",
+ NL80211_MESHCONF_HWMP_ACTIVE_PATH_TIMEOUT: "NL80211_MESHCONF_HWMP_ACTIVE_PATH_TIMEOUT",
+ NL80211_MESHCONF_HWMP_PREQ_MIN_INTERVAL: "NL80211_MESHCONF_HWMP_PREQ_MIN_INTERVAL",
+ NL80211_MESHCONF_HWMP_NET_DIAM_TRVS_TIME: "NL80211_MESHCONF_HWMP_NET_DIAM_TRVS_TIME",
+ NL80211_MESHCONF_HWMP_ROOTMODE: "NL80211_MESHCONF_HWMP_ROOTMODE",
+ NL80211_MESHCONF_ELEMENT_TTL: "NL80211_MESHCONF_ELEMENT_TTL",
+ NL80211_MESHCONF_HWMP_RANN_INTERVAL: "NL80211_MESHCONF_HWMP_RANN_INTERVAL",
+ NL80211_MESHCONF_GATE_ANNOUNCEMENTS: "NL80211_MESHCONF_GATE_ANNOUNCEMENTS",
+ NL80211_MESHCONF_HWMP_PERR_MIN_INTERVAL: "NL80211_MESHCONF_HWMP_PERR_MIN_INTERVAL",
+ NL80211_MESHCONF_FORWARDING: "NL80211_MESHCONF_FORWARDING",
+ NL80211_MESHCONF_RSSI_THRESHOLD: "NL80211_MESHCONF_RSSI_THRESHOLD",
+ NL80211_MESHCONF_SYNC_OFFSET_MAX_NEIGHBOR: "NL80211_MESHCONF_SYNC_OFFSET_MAX_NEIGHBOR",
+ NL80211_MESHCONF_HT_OPMODE: "NL80211_MESHCONF_HT_OPMODE",
+ NL80211_MESHCONF_HWMP_PATH_TO_ROOT_TIMEOUT: "NL80211_MESHCONF_HWMP_PATH_TO_ROOT_TIMEOUT",
+ NL80211_MESHCONF_HWMP_ROOT_INTERVAL: "NL80211_MESHCONF_HWMP_ROOT_INTERVAL",
+ NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL: "NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL",
+ NL80211_MESHCONF_POWER_MODE: "NL80211_MESHCONF_POWER_MODE",
+ NL80211_MESHCONF_AWAKE_WINDOW: "NL80211_MESHCONF_AWAKE_WINDOW",
+ NL80211_MESHCONF_PLINK_TIMEOUT: "NL80211_MESHCONF_PLINK_TIMEOUT",
+ __NL80211_MESHCONF_ATTR_AFTER_LAST: "__NL80211_MESHCONF_ATTR_AFTER_LAST",
+}
+nl80211_mesh_setup_params2str = {
+ __NL80211_MESH_SETUP_INVALID: "__NL80211_MESH_SETUP_INVALID",
+ NL80211_MESH_SETUP_ENABLE_VENDOR_PATH_SEL: "NL80211_MESH_SETUP_ENABLE_VENDOR_PATH_SEL",
+ NL80211_MESH_SETUP_ENABLE_VENDOR_METRIC: "NL80211_MESH_SETUP_ENABLE_VENDOR_METRIC",
+ NL80211_MESH_SETUP_IE: "NL80211_MESH_SETUP_IE",
+ NL80211_MESH_SETUP_USERSPACE_AUTH: "NL80211_MESH_SETUP_USERSPACE_AUTH",
+ NL80211_MESH_SETUP_USERSPACE_AMPE: "NL80211_MESH_SETUP_USERSPACE_AMPE",
+ NL80211_MESH_SETUP_ENABLE_VENDOR_SYNC: "NL80211_MESH_SETUP_ENABLE_VENDOR_SYNC",
+ NL80211_MESH_SETUP_USERSPACE_MPM: "NL80211_MESH_SETUP_USERSPACE_MPM",
+ NL80211_MESH_SETUP_AUTH_PROTOCOL: "NL80211_MESH_SETUP_AUTH_PROTOCOL",
+ __NL80211_MESH_SETUP_ATTR_AFTER_LAST: "__NL80211_MESH_SETUP_ATTR_AFTER_LAST",
+}
+nl80211_txq_attr2str = {
+ __NL80211_TXQ_ATTR_INVALID: "__NL80211_TXQ_ATTR_INVALID",
+ NL80211_TXQ_ATTR_AC: "NL80211_TXQ_ATTR_AC",
+ NL80211_TXQ_ATTR_TXOP: "NL80211_TXQ_ATTR_TXOP",
+ NL80211_TXQ_ATTR_CWMIN: "NL80211_TXQ_ATTR_CWMIN",
+ NL80211_TXQ_ATTR_CWMAX: "NL80211_TXQ_ATTR_CWMAX",
+ NL80211_TXQ_ATTR_AIFS: "NL80211_TXQ_ATTR_AIFS",
+ __NL80211_TXQ_ATTR_AFTER_LAST: "__NL80211_TXQ_ATTR_AFTER_LAST",
+}
+nl80211_ac2str = {
+ NL80211_AC_VO: "NL80211_AC_VO",
+ NL80211_AC_VI: "NL80211_AC_VI",
+ NL80211_AC_BE: "NL80211_AC_BE",
+ NL80211_AC_BK: "NL80211_AC_BK",
+ NL80211_NUM_ACS: "NL80211_NUM_ACS",
+}
+nl80211_channel_type2str = {
+ NL80211_CHAN_NO_HT: "NL80211_CHAN_NO_HT",
+ NL80211_CHAN_HT20: "NL80211_CHAN_HT20",
+ NL80211_CHAN_HT40MINUS: "NL80211_CHAN_HT40MINUS",
+ NL80211_CHAN_HT40PLUS: "NL80211_CHAN_HT40PLUS",
+}
+nl80211_chan_width2str = {
+ NL80211_CHAN_WIDTH_20_NOHT: "NL80211_CHAN_WIDTH_20_NOHT",
+ NL80211_CHAN_WIDTH_20: "NL80211_CHAN_WIDTH_20",
+ NL80211_CHAN_WIDTH_40: "NL80211_CHAN_WIDTH_40",
+ NL80211_CHAN_WIDTH_80: "NL80211_CHAN_WIDTH_80",
+ NL80211_CHAN_WIDTH_80P80: "NL80211_CHAN_WIDTH_80P80",
+ NL80211_CHAN_WIDTH_160: "NL80211_CHAN_WIDTH_160",
+}
+nl80211_bss2str = {
+ __NL80211_BSS_INVALID: "__NL80211_BSS_INVALID",
+ NL80211_BSS_BSSID: "NL80211_BSS_BSSID",
+ NL80211_BSS_FREQUENCY: "NL80211_BSS_FREQUENCY",
+ NL80211_BSS_TSF: "NL80211_BSS_TSF",
+ NL80211_BSS_BEACON_INTERVAL: "NL80211_BSS_BEACON_INTERVAL",
+ NL80211_BSS_CAPABILITY: "NL80211_BSS_CAPABILITY",
+ NL80211_BSS_INFORMATION_ELEMENTS: "NL80211_BSS_INFORMATION_ELEMENTS",
+ NL80211_BSS_SIGNAL_MBM: "NL80211_BSS_SIGNAL_MBM",
+ NL80211_BSS_SIGNAL_UNSPEC: "NL80211_BSS_SIGNAL_UNSPEC",
+ NL80211_BSS_STATUS: "NL80211_BSS_STATUS",
+ NL80211_BSS_SEEN_MS_AGO: "NL80211_BSS_SEEN_MS_AGO",
+ NL80211_BSS_BEACON_IES: "NL80211_BSS_BEACON_IES",
+ __NL80211_BSS_AFTER_LAST: "__NL80211_BSS_AFTER_LAST",
+}
+nl80211_bss_status2str = {
+ NL80211_BSS_STATUS_AUTHENTICATED: "NL80211_BSS_STATUS_AUTHENTICATED",
+ NL80211_BSS_STATUS_ASSOCIATED: "NL80211_BSS_STATUS_ASSOCIATED",
+ NL80211_BSS_STATUS_IBSS_JOINED: "NL80211_BSS_STATUS_IBSS_JOINED",
+}
+nl80211_auth_type2str = {
+ NL80211_AUTHTYPE_OPEN_SYSTEM: "NL80211_AUTHTYPE_OPEN_SYSTEM",
+ NL80211_AUTHTYPE_SHARED_KEY: "NL80211_AUTHTYPE_SHARED_KEY",
+ NL80211_AUTHTYPE_FT: "NL80211_AUTHTYPE_FT",
+ NL80211_AUTHTYPE_NETWORK_EAP: "NL80211_AUTHTYPE_NETWORK_EAP",
+ NL80211_AUTHTYPE_SAE: "NL80211_AUTHTYPE_SAE",
+ __NL80211_AUTHTYPE_NUM: "__NL80211_AUTHTYPE_NUM",
+ NL80211_AUTHTYPE_AUTOMATIC: "NL80211_AUTHTYPE_AUTOMATIC",
+}
+nl80211_key_type2str = {
+ NL80211_KEYTYPE_GROUP: "NL80211_KEYTYPE_GROUP",
+ NL80211_KEYTYPE_PAIRWISE: "NL80211_KEYTYPE_PAIRWISE",
+ NL80211_KEYTYPE_PEERKEY: "NL80211_KEYTYPE_PEERKEY",
+ NUM_NL80211_KEYTYPES: "NUM_NL80211_KEYTYPES",
+}
+nl80211_mfp2str = {
+ NL80211_MFP_NO: "NL80211_MFP_NO",
+ NL80211_MFP_REQUIRED: "NL80211_MFP_REQUIRED",
+}
+nl80211_wpa_versions2str = {
+ NL80211_WPA_VERSION_1: "NL80211_WPA_VERSION_1",
+ NL80211_WPA_VERSION_2: "NL80211_WPA_VERSION_2",
+}
+nl80211_key_default_types2str = {
+ __NL80211_KEY_DEFAULT_TYPE_INVALID: "__NL80211_KEY_DEFAULT_TYPE_INVALID",
+ NL80211_KEY_DEFAULT_TYPE_UNICAST: "NL80211_KEY_DEFAULT_TYPE_UNICAST",
+ NL80211_KEY_DEFAULT_TYPE_MULTICAST: "NL80211_KEY_DEFAULT_TYPE_MULTICAST",
+ NUM_NL80211_KEY_DEFAULT_TYPES: "NUM_NL80211_KEY_DEFAULT_TYPES",
+}
+nl80211_key_attributes2str = {
+ __NL80211_KEY_INVALID: "__NL80211_KEY_INVALID",
+ NL80211_KEY_DATA: "NL80211_KEY_DATA",
+ NL80211_KEY_IDX: "NL80211_KEY_IDX",
+ NL80211_KEY_CIPHER: "NL80211_KEY_CIPHER",
+ NL80211_KEY_SEQ: "NL80211_KEY_SEQ",
+ NL80211_KEY_DEFAULT: "NL80211_KEY_DEFAULT",
+ NL80211_KEY_DEFAULT_MGMT: "NL80211_KEY_DEFAULT_MGMT",
+ NL80211_KEY_TYPE: "NL80211_KEY_TYPE",
+ NL80211_KEY_DEFAULT_TYPES: "NL80211_KEY_DEFAULT_TYPES",
+ __NL80211_KEY_AFTER_LAST: "__NL80211_KEY_AFTER_LAST",
+}
+nl80211_tx_rate_attributes2str = {
+ __NL80211_TXRATE_INVALID: "__NL80211_TXRATE_INVALID",
+ NL80211_TXRATE_LEGACY: "NL80211_TXRATE_LEGACY",
+ NL80211_TXRATE_MCS: "NL80211_TXRATE_MCS",
+ __NL80211_TXRATE_AFTER_LAST: "__NL80211_TXRATE_AFTER_LAST",
+}
+nl80211_band2str = {
+ NL80211_BAND_2GHZ: "NL80211_BAND_2GHZ",
+ NL80211_BAND_5GHZ: "NL80211_BAND_5GHZ",
+ NL80211_BAND_60GHZ: "NL80211_BAND_60GHZ",
+}
+nl80211_ps_state2str = {
+ NL80211_PS_DISABLED: "NL80211_PS_DISABLED",
+ NL80211_PS_ENABLED: "NL80211_PS_ENABLED",
+}
+nl80211_attr_cqm2str = {
+ __NL80211_ATTR_CQM_INVALID: "__NL80211_ATTR_CQM_INVALID",
+ NL80211_ATTR_CQM_RSSI_THOLD: "NL80211_ATTR_CQM_RSSI_THOLD",
+ NL80211_ATTR_CQM_RSSI_HYST: "NL80211_ATTR_CQM_RSSI_HYST",
+ NL80211_ATTR_CQM_RSSI_THRESHOLD_EVENT: "NL80211_ATTR_CQM_RSSI_THRESHOLD_EVENT",
+ NL80211_ATTR_CQM_PKT_LOSS_EVENT: "NL80211_ATTR_CQM_PKT_LOSS_EVENT",
+ NL80211_ATTR_CQM_TXE_RATE: "NL80211_ATTR_CQM_TXE_RATE",
+ NL80211_ATTR_CQM_TXE_PKTS: "NL80211_ATTR_CQM_TXE_PKTS",
+ NL80211_ATTR_CQM_TXE_INTVL: "NL80211_ATTR_CQM_TXE_INTVL",
+ __NL80211_ATTR_CQM_AFTER_LAST: "__NL80211_ATTR_CQM_AFTER_LAST",
+}
+nl80211_cqm_rssi_threshold_event2str = {
+ NL80211_CQM_RSSI_THRESHOLD_EVENT_LOW: "NL80211_CQM_RSSI_THRESHOLD_EVENT_LOW",
+ NL80211_CQM_RSSI_THRESHOLD_EVENT_HIGH: "NL80211_CQM_RSSI_THRESHOLD_EVENT_HIGH",
+ NL80211_CQM_RSSI_BEACON_LOSS_EVENT: "NL80211_CQM_RSSI_BEACON_LOSS_EVENT",
+}
+nl80211_tx_power_setting2str = {
+ NL80211_TX_POWER_AUTOMATIC: "NL80211_TX_POWER_AUTOMATIC",
+ NL80211_TX_POWER_LIMITED: "NL80211_TX_POWER_LIMITED",
+ NL80211_TX_POWER_FIXED: "NL80211_TX_POWER_FIXED",
+}
+nl80211_wowlan_packet_pattern_attr2str = {
+ __NL80211_WOWLAN_PKTPAT_INVALID: "__NL80211_WOWLAN_PKTPAT_INVALID",
+ NL80211_WOWLAN_PKTPAT_MASK: "NL80211_WOWLAN_PKTPAT_MASK",
+ NL80211_WOWLAN_PKTPAT_PATTERN: "NL80211_WOWLAN_PKTPAT_PATTERN",
+ NL80211_WOWLAN_PKTPAT_OFFSET: "NL80211_WOWLAN_PKTPAT_OFFSET",
+ NUM_NL80211_WOWLAN_PKTPAT: "NUM_NL80211_WOWLAN_PKTPAT",
+}
+nl80211_wowlan_triggers2str = {
+ __NL80211_WOWLAN_TRIG_INVALID: "__NL80211_WOWLAN_TRIG_INVALID",
+ NL80211_WOWLAN_TRIG_ANY: "NL80211_WOWLAN_TRIG_ANY",
+ NL80211_WOWLAN_TRIG_DISCONNECT: "NL80211_WOWLAN_TRIG_DISCONNECT",
+ NL80211_WOWLAN_TRIG_MAGIC_PKT: "NL80211_WOWLAN_TRIG_MAGIC_PKT",
+ NL80211_WOWLAN_TRIG_PKT_PATTERN: "NL80211_WOWLAN_TRIG_PKT_PATTERN",
+ NL80211_WOWLAN_TRIG_GTK_REKEY_SUPPORTED: "NL80211_WOWLAN_TRIG_GTK_REKEY_SUPPORTED",
+ NL80211_WOWLAN_TRIG_GTK_REKEY_FAILURE: "NL80211_WOWLAN_TRIG_GTK_REKEY_FAILURE",
+ NL80211_WOWLAN_TRIG_EAP_IDENT_REQUEST: "NL80211_WOWLAN_TRIG_EAP_IDENT_REQUEST",
+ NL80211_WOWLAN_TRIG_4WAY_HANDSHAKE: "NL80211_WOWLAN_TRIG_4WAY_HANDSHAKE",
+ NL80211_WOWLAN_TRIG_RFKILL_RELEASE: "NL80211_WOWLAN_TRIG_RFKILL_RELEASE",
+ NL80211_WOWLAN_TRIG_WAKEUP_PKT_80211: "NL80211_WOWLAN_TRIG_WAKEUP_PKT_80211",
+ NL80211_WOWLAN_TRIG_WAKEUP_PKT_80211_LEN: "NL80211_WOWLAN_TRIG_WAKEUP_PKT_80211_LEN",
+ NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023: "NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023",
+ NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023_LEN: "NL80211_WOWLAN_TRIG_WAKEUP_PKT_8023_LEN",
+ NL80211_WOWLAN_TRIG_TCP_CONNECTION: "NL80211_WOWLAN_TRIG_TCP_CONNECTION",
+ NL80211_WOWLAN_TRIG_WAKEUP_TCP_MATCH: "NL80211_WOWLAN_TRIG_WAKEUP_TCP_MATCH",
+ NL80211_WOWLAN_TRIG_WAKEUP_TCP_CONNLOST: "NL80211_WOWLAN_TRIG_WAKEUP_TCP_CONNLOST",
+ NL80211_WOWLAN_TRIG_WAKEUP_TCP_NOMORETOKENS: "NL80211_WOWLAN_TRIG_WAKEUP_TCP_NOMORETOKENS",
+ NUM_NL80211_WOWLAN_TRIG: "NUM_NL80211_WOWLAN_TRIG",
+}
+nl80211_wowlan_tcp_attrs2str = {
+ __NL80211_WOWLAN_TCP_INVALID: "__NL80211_WOWLAN_TCP_INVALID",
+ NL80211_WOWLAN_TCP_SRC_IPV4: "NL80211_WOWLAN_TCP_SRC_IPV4",
+ NL80211_WOWLAN_TCP_DST_IPV4: "NL80211_WOWLAN_TCP_DST_IPV4",
+ NL80211_WOWLAN_TCP_DST_MAC: "NL80211_WOWLAN_TCP_DST_MAC",
+ NL80211_WOWLAN_TCP_SRC_PORT: "NL80211_WOWLAN_TCP_SRC_PORT",
+ NL80211_WOWLAN_TCP_DST_PORT: "NL80211_WOWLAN_TCP_DST_PORT",
+ NL80211_WOWLAN_TCP_DATA_PAYLOAD: "NL80211_WOWLAN_TCP_DATA_PAYLOAD",
+ NL80211_WOWLAN_TCP_DATA_PAYLOAD_SEQ: "NL80211_WOWLAN_TCP_DATA_PAYLOAD_SEQ",
+ NL80211_WOWLAN_TCP_DATA_PAYLOAD_TOKEN: "NL80211_WOWLAN_TCP_DATA_PAYLOAD_TOKEN",
+ NL80211_WOWLAN_TCP_DATA_INTERVAL: "NL80211_WOWLAN_TCP_DATA_INTERVAL",
+ NL80211_WOWLAN_TCP_WAKE_PAYLOAD: "NL80211_WOWLAN_TCP_WAKE_PAYLOAD",
+ NL80211_WOWLAN_TCP_WAKE_MASK: "NL80211_WOWLAN_TCP_WAKE_MASK",
+ NUM_NL80211_WOWLAN_TCP: "NUM_NL80211_WOWLAN_TCP",
+}
+nl80211_iface_limit_attrs2str = {
+ NL80211_IFACE_LIMIT_UNSPEC: "NL80211_IFACE_LIMIT_UNSPEC",
+ NL80211_IFACE_LIMIT_MAX: "NL80211_IFACE_LIMIT_MAX",
+ NL80211_IFACE_LIMIT_TYPES: "NL80211_IFACE_LIMIT_TYPES",
+ NUM_NL80211_IFACE_LIMIT: "NUM_NL80211_IFACE_LIMIT",
+}
+nl80211_if_combination_attrs2str = {
+ NL80211_IFACE_COMB_UNSPEC: "NL80211_IFACE_COMB_UNSPEC",
+ NL80211_IFACE_COMB_LIMITS: "NL80211_IFACE_COMB_LIMITS",
+ NL80211_IFACE_COMB_MAXNUM: "NL80211_IFACE_COMB_MAXNUM",
+ NL80211_IFACE_COMB_STA_AP_BI_MATCH: "NL80211_IFACE_COMB_STA_AP_BI_MATCH",
+ NL80211_IFACE_COMB_NUM_CHANNELS: "NL80211_IFACE_COMB_NUM_CHANNELS",
+ NL80211_IFACE_COMB_RADAR_DETECT_WIDTHS: "NL80211_IFACE_COMB_RADAR_DETECT_WIDTHS",
+ NUM_NL80211_IFACE_COMB: "NUM_NL80211_IFACE_COMB",
+}
+nl80211_plink_state2str = {
+ NL80211_PLINK_LISTEN: "NL80211_PLINK_LISTEN",
+ NL80211_PLINK_OPN_SNT: "NL80211_PLINK_OPN_SNT",
+ NL80211_PLINK_OPN_RCVD: "NL80211_PLINK_OPN_RCVD",
+ NL80211_PLINK_CNF_RCVD: "NL80211_PLINK_CNF_RCVD",
+ NL80211_PLINK_ESTAB: "NL80211_PLINK_ESTAB",
+ NL80211_PLINK_HOLDING: "NL80211_PLINK_HOLDING",
+ NL80211_PLINK_BLOCKED: "NL80211_PLINK_BLOCKED",
+ NUM_NL80211_PLINK_STATES: "NUM_NL80211_PLINK_STATES",
+}
+plink_actions2str = {
+ NL80211_PLINK_ACTION_NO_ACTION: "NL80211_PLINK_ACTION_NO_ACTION",
+ NL80211_PLINK_ACTION_OPEN: "NL80211_PLINK_ACTION_OPEN",
+ NL80211_PLINK_ACTION_BLOCK: "NL80211_PLINK_ACTION_BLOCK",
+ NUM_NL80211_PLINK_ACTIONS: "NUM_NL80211_PLINK_ACTIONS",
+}
+nl80211_rekey_data2str = {
+ __NL80211_REKEY_DATA_INVALID: "__NL80211_REKEY_DATA_INVALID",
+ NL80211_REKEY_DATA_KEK: "NL80211_REKEY_DATA_KEK",
+ NL80211_REKEY_DATA_KCK: "NL80211_REKEY_DATA_KCK",
+ NL80211_REKEY_DATA_REPLAY_CTR: "NL80211_REKEY_DATA_REPLAY_CTR",
+ NUM_NL80211_REKEY_DATA: "NUM_NL80211_REKEY_DATA",
+}
+nl80211_hidden_ssid2str = {
+ NL80211_HIDDEN_SSID_NOT_IN_USE: "NL80211_HIDDEN_SSID_NOT_IN_USE",
+ NL80211_HIDDEN_SSID_ZERO_LEN: "NL80211_HIDDEN_SSID_ZERO_LEN",
+ NL80211_HIDDEN_SSID_ZERO_CONTENTS: "NL80211_HIDDEN_SSID_ZERO_CONTENTS",
+}
+nl80211_sta_wme_attr2str = {
+ __NL80211_STA_WME_INVALID: "__NL80211_STA_WME_INVALID",
+ NL80211_STA_WME_UAPSD_QUEUES: "NL80211_STA_WME_UAPSD_QUEUES",
+ NL80211_STA_WME_MAX_SP: "NL80211_STA_WME_MAX_SP",
+ __NL80211_STA_WME_AFTER_LAST: "__NL80211_STA_WME_AFTER_LAST",
+}
+nl80211_pmksa_candidate_attr2str = {
+ __NL80211_PMKSA_CANDIDATE_INVALID: "__NL80211_PMKSA_CANDIDATE_INVALID",
+ NL80211_PMKSA_CANDIDATE_INDEX: "NL80211_PMKSA_CANDIDATE_INDEX",
+ NL80211_PMKSA_CANDIDATE_BSSID: "NL80211_PMKSA_CANDIDATE_BSSID",
+ NL80211_PMKSA_CANDIDATE_PREAUTH: "NL80211_PMKSA_CANDIDATE_PREAUTH",
+ NUM_NL80211_PMKSA_CANDIDATE: "NUM_NL80211_PMKSA_CANDIDATE",
+}
+nl80211_tdls_operation2str = {
+ NL80211_TDLS_DISCOVERY_REQ: "NL80211_TDLS_DISCOVERY_REQ",
+ NL80211_TDLS_SETUP: "NL80211_TDLS_SETUP",
+ NL80211_TDLS_TEARDOWN: "NL80211_TDLS_TEARDOWN",
+ NL80211_TDLS_ENABLE_LINK: "NL80211_TDLS_ENABLE_LINK",
+ NL80211_TDLS_DISABLE_LINK: "NL80211_TDLS_DISABLE_LINK",
+}
+nl80211_feature_flags2str = {
+ NL80211_FEATURE_SK_TX_STATUS: "NL80211_FEATURE_SK_TX_STATUS",
+ NL80211_FEATURE_HT_IBSS: "NL80211_FEATURE_HT_IBSS",
+ NL80211_FEATURE_INACTIVITY_TIMER: "NL80211_FEATURE_INACTIVITY_TIMER",
+ NL80211_FEATURE_CELL_BASE_REG_HINTS: "NL80211_FEATURE_CELL_BASE_REG_HINTS",
+ NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL: "NL80211_FEATURE_P2P_DEVICE_NEEDS_CHANNEL",
+ NL80211_FEATURE_SAE: "NL80211_FEATURE_SAE",
+ NL80211_FEATURE_LOW_PRIORITY_SCAN: "NL80211_FEATURE_LOW_PRIORITY_SCAN",
+ NL80211_FEATURE_SCAN_FLUSH: "NL80211_FEATURE_SCAN_FLUSH",
+ NL80211_FEATURE_AP_SCAN: "NL80211_FEATURE_AP_SCAN",
+ NL80211_FEATURE_VIF_TXPOWER: "NL80211_FEATURE_VIF_TXPOWER",
+ NL80211_FEATURE_NEED_OBSS_SCAN: "NL80211_FEATURE_NEED_OBSS_SCAN",
+ NL80211_FEATURE_P2P_GO_CTWIN: "NL80211_FEATURE_P2P_GO_CTWIN",
+ NL80211_FEATURE_P2P_GO_OPPPS: "NL80211_FEATURE_P2P_GO_OPPPS",
+ NL80211_FEATURE_ADVERTISE_CHAN_LIMITS: "NL80211_FEATURE_ADVERTISE_CHAN_LIMITS",
+ NL80211_FEATURE_FULL_AP_CLIENT_STATE: "NL80211_FEATURE_FULL_AP_CLIENT_STATE",
+ NL80211_FEATURE_USERSPACE_MPM: "NL80211_FEATURE_USERSPACE_MPM",
+ NL80211_FEATURE_ACTIVE_MONITOR: "NL80211_FEATURE_ACTIVE_MONITOR",
+}
+nl80211_probe_resp_offload_support_attr2str = {
+ NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS: "NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS",
+ NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS2: "NL80211_PROBE_RESP_OFFLOAD_SUPPORT_WPS2",
+ NL80211_PROBE_RESP_OFFLOAD_SUPPORT_P2P: "NL80211_PROBE_RESP_OFFLOAD_SUPPORT_P2P",
+ NL80211_PROBE_RESP_OFFLOAD_SUPPORT_80211U: "NL80211_PROBE_RESP_OFFLOAD_SUPPORT_80211U",
+}
+nl80211_connect_failed_reason2str = {
+ NL80211_CONN_FAIL_MAX_CLIENTS: "NL80211_CONN_FAIL_MAX_CLIENTS",
+ NL80211_CONN_FAIL_BLOCKED_CLIENT: "NL80211_CONN_FAIL_BLOCKED_CLIENT",
+}
+nl80211_scan_flags2str = {
+ NL80211_SCAN_FLAG_LOW_PRIORITY: "NL80211_SCAN_FLAG_LOW_PRIORITY",
+ NL80211_SCAN_FLAG_FLUSH: "NL80211_SCAN_FLAG_FLUSH",
+ NL80211_SCAN_FLAG_AP: "NL80211_SCAN_FLAG_AP",
+}
+nl80211_acl_policy2str = {
+ NL80211_ACL_POLICY_ACCEPT_UNLESS_LISTED: "NL80211_ACL_POLICY_ACCEPT_UNLESS_LISTED",
+ NL80211_ACL_POLICY_DENY_UNLESS_LISTED: "NL80211_ACL_POLICY_DENY_UNLESS_LISTED",
+}
+nl80211_radar_event2str = {
+ NL80211_RADAR_DETECTED: "NL80211_RADAR_DETECTED",
+ NL80211_RADAR_CAC_FINISHED: "NL80211_RADAR_CAC_FINISHED",
+ NL80211_RADAR_CAC_ABORTED: "NL80211_RADAR_CAC_ABORTED",
+ NL80211_RADAR_NOP_FINISHED: "NL80211_RADAR_NOP_FINISHED",
+}
+nl80211_dfs_state2str = {
+ NL80211_DFS_USABLE: "NL80211_DFS_USABLE",
+ NL80211_DFS_UNAVAILABLE: "NL80211_DFS_UNAVAILABLE",
+ NL80211_DFS_AVAILABLE: "NL80211_DFS_AVAILABLE",
+}
+nl80211_protocol_features2str = {
+ NL80211_PROTOCOL_FEATURE_SPLIT_WIPHY_DUMP: "NL80211_PROTOCOL_FEATURE_SPLIT_WIPHY_DUMP",
+}
+nl80211_crit_proto_id2str = {
+ NL80211_CRIT_PROTO_UNSPEC: "NL80211_CRIT_PROTO_UNSPEC",
+ NL80211_CRIT_PROTO_DHCP: "NL80211_CRIT_PROTO_DHCP",
+ NL80211_CRIT_PROTO_EAPOL: "NL80211_CRIT_PROTO_EAPOL",
+ NL80211_CRIT_PROTO_APIPA: "NL80211_CRIT_PROTO_APIPA",
+ NUM_NL80211_CRIT_PROTO: "NUM_NL80211_CRIT_PROTO",
+}
diff --git a/ap/lib/libnl/libnl-3.2.25/python/examples/wiphy.py b/ap/lib/libnl/libnl-3.2.25/python/examples/wiphy.py
new file mode 100644
index 0000000..73e2d4d
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/examples/wiphy.py
@@ -0,0 +1,141 @@
+import netlink.capi as nl
+import netlink.genl.capi as genl
+import nl80211
+import sys
+import traceback
+
+class test_class:
+ def __init__(self):
+ self.done = 1;
+
+def freq_to_ch(freq):
+ if freq == 2484:
+ return 14;
+
+ if freq < 2484:
+ return (freq - 2407) / 5;
+
+ # FIXME: dot11ChannelStartingFactor (802.11-2007 17.3.8.3.2)
+ if freq < 45000:
+ return freq/5 - 1000;
+
+ if freq >= 58320 and freq <= 64800:
+ return (freq - 56160) / 2160;
+
+ return 0;
+
+def handle_freq(attr, pol):
+ e, fattr = nl.py_nla_parse_nested(nl80211.NL80211_FREQUENCY_ATTR_MAX, attr, pol)
+ if nl80211.NL80211_FREQUENCY_ATTR_FREQ in fattr:
+ freq = nl.nla_get_u32(fattr[nl80211.NL80211_FREQUENCY_ATTR_FREQ])
+ sys.stdout.write("\t\tfreq %d MHz [%d]" % (freq, freq_to_ch(freq)))
+ if nl80211.NL80211_FREQUENCY_ATTR_MAX_TX_POWER in fattr and not (nl80211.NL80211_FREQUENCY_ATTR_DISABLED in fattr):
+ sys.stdout.write(" (%.1f dBm)" % (0.01 * nl.nla_get_u32(fattr[nl80211.NL80211_FREQUENCY_ATTR_MAX_TX_POWER])))
+ if nl80211.NL80211_FREQUENCY_ATTR_DISABLED in fattr:
+ sys.stdout.write(" (disabled)")
+ sys.stdout.write("\n")
+
+def handle_band(attr, fpol):
+ e, battr = nl.py_nla_parse_nested(nl80211.NL80211_BAND_ATTR_MAX, attr, None)
+ print("\tband %d:" % nl.nla_type(attr))
+ if nl80211.NL80211_BAND_ATTR_FREQS in battr:
+ for fattr in nl.nla_get_nested(battr[nl80211.NL80211_BAND_ATTR_FREQS]):
+ handle_freq(fattr, fpol)
+
+def cipher_name(suite):
+ suite_val = '%02x%02x%02x%02x' % tuple(reversed(suite))
+ if suite_val == '000fac01':
+ return "WEP40 (00-0f-ac:1)"
+ elif suite_val == '000fac05':
+ return "WEP104 (00-0f-ac:5)"
+ elif suite_val == '000fac02':
+ return "TKIP (00-0f-ac:2)"
+ elif suite_val == '000fac04':
+ return "CCMP (00-0f-ac:4)"
+ elif suite_val == '000fac06':
+ return "CMAC (00-0f-ac:6)"
+ elif suite_val == '000fac08':
+ return "GCMP (00-0f-ac:8)"
+ elif suite_val == '00147201':
+ return "WPI-SMS4 (00-14-72:1)"
+ else:
+ return suite_val
+
+def msg_handler(m, a):
+ try:
+ e, attr = genl.py_genlmsg_parse(nl.nlmsg_hdr(m), 0,
+ nl80211.NL80211_ATTR_MAX, None)
+ if nl80211.NL80211_ATTR_WIPHY_NAME in attr:
+ print('wiphy %s' % nl.nla_get_string(attr[nl80211.NL80211_ATTR_WIPHY_NAME]))
+ if nl80211.NL80211_ATTR_WIPHY_BANDS in attr:
+ fpol = nl.nla_policy_array(nl80211.NL80211_FREQUENCY_ATTR_MAX + 1)
+ fpol[nl80211.NL80211_FREQUENCY_ATTR_FREQ].type = nl.NLA_U32
+ fpol[nl80211.NL80211_FREQUENCY_ATTR_DISABLED].type = nl.NLA_FLAG
+ fpol[nl80211.NL80211_FREQUENCY_ATTR_PASSIVE_SCAN].type = nl.NLA_FLAG
+ fpol[nl80211.NL80211_FREQUENCY_ATTR_NO_IBSS].type = nl.NLA_FLAG
+ fpol[nl80211.NL80211_FREQUENCY_ATTR_RADAR].type = nl.NLA_FLAG
+ fpol[nl80211.NL80211_FREQUENCY_ATTR_MAX_TX_POWER].type = nl.NLA_U32
+
+ nattrs = nl.nla_get_nested(attr[nl80211.NL80211_ATTR_WIPHY_BANDS])
+ for nattr in nattrs:
+ handle_band(nattr, fpol)
+ if nl80211.NL80211_ATTR_CIPHER_SUITES in attr:
+ ciphers = nl.nla_data(attr[nl80211.NL80211_ATTR_CIPHER_SUITES])
+ num = len(ciphers) / 4
+ if num > 0:
+ print("\tSupported Ciphers:");
+ for i in range(0, num, 4):
+ print("\t\t* %s" % cipher_name(ciphers[i:i+4]))
+ if nl80211.NL80211_ATTR_SUPPORTED_IFTYPES in attr:
+ print("\tSupported interface modes:")
+ ifattr = nl.nla_get_nested(attr[nl80211.NL80211_ATTR_SUPPORTED_IFTYPES])
+ for nl_mode in ifattr:
+ print("\t\t* %s" % nl80211.nl80211_iftype2str[nl.nla_type(nl_mode)])
+ if nl80211.NL80211_ATTR_SOFTWARE_IFTYPES in attr:
+ print("\tsoftware interface modes (can always be added):")
+ ifattr = nl.nla_get_nested(attr[nl80211.NL80211_ATTR_SOFTWARE_IFTYPES])
+ for nl_mode in ifattr:
+ print("\t\t* %s" % nl80211.nl80211_iftype2str[nl.nla_type(nl_mode)])
+ return nl.NL_SKIP
+ except Exception as e:
+ (t,v,tb) = sys.exc_info()
+ print v.message
+ traceback.print_tb(tb)
+
+def error_handler(err, a):
+ a.done = err.error
+ return nl.NL_STOP
+
+def finish_handler(m, a):
+ return nl.NL_SKIP
+
+def ack_handler(m, a):
+ a.done = 0
+ return nl.NL_STOP
+
+try:
+ cbd = test_class()
+ tx_cb = nl.nl_cb_alloc(nl.NL_CB_DEFAULT)
+ rx_cb = nl.nl_cb_clone(tx_cb)
+ s = nl.nl_socket_alloc_cb(tx_cb)
+ nl.py_nl_cb_err(rx_cb, nl.NL_CB_CUSTOM, error_handler, cbd);
+ nl.py_nl_cb_set(rx_cb, nl.NL_CB_FINISH, nl.NL_CB_CUSTOM, finish_handler, cbd);
+ nl.py_nl_cb_set(rx_cb, nl.NL_CB_ACK, nl.NL_CB_CUSTOM, ack_handler, cbd);
+ nl.py_nl_cb_set(rx_cb, nl.NL_CB_VALID, nl.NL_CB_CUSTOM, msg_handler, cbd);
+
+ genl.genl_connect(s)
+ family = genl.genl_ctrl_resolve(s, 'nl80211')
+ m = nl.nlmsg_alloc()
+ genl.genlmsg_put(m, 0, 0, family, 0, 0, nl80211.NL80211_CMD_GET_WIPHY, 0)
+ nl.nla_put_u32(m, nl80211.NL80211_ATTR_WIPHY, 7)
+
+ err = nl.nl_send_auto_complete(s, m);
+ if err < 0:
+ nl.nlmsg_free(msg)
+
+ while cbd.done > 0 and not err < 0:
+ err = nl.nl_recvmsgs(s, rx_cb)
+except Exception as e:
+ (t, v, tb) = sys.exc_info()
+ print v.message
+ traceback.print_tb(tb)
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/netlink/Makefile.am
new file mode 100644
index 0000000..1f6eaf8
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/Makefile.am
@@ -0,0 +1,11 @@
+# -*- Makefile -*-
+
+SUBDIRS = route genl
+
+EXTRA_DIST = \
+ capi.i \
+ fixes.h \
+ __init__.py \
+ core.py \
+ util.py \
+ utils.h
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/netlink/Makefile.in
new file mode 100644
index 0000000..b99c5e1
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/Makefile.in
@@ -0,0 +1,628 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python/netlink
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+ ctags-recursive dvi-recursive html-recursive info-recursive \
+ install-data-recursive install-dvi-recursive \
+ install-exec-recursive install-html-recursive \
+ install-info-recursive install-pdf-recursive \
+ install-ps-recursive install-recursive installcheck-recursive \
+ installdirs-recursive pdf-recursive ps-recursive \
+ tags-recursive uninstall-recursive
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \
+ distclean-recursive maintainer-clean-recursive
+am__recursive_targets = \
+ $(RECURSIVE_TARGETS) \
+ $(RECURSIVE_CLEAN_TARGETS) \
+ $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
+ distdir
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates. Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+ BEGIN { nonempty = 0; } \
+ { items[$$0] = 1; nonempty = 1; } \
+ END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique. This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+ list='$(am__tagged_files)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | $(am__uniquify_input)`
+ETAGS = etags
+CTAGS = ctags
+DIST_SUBDIRS = $(SUBDIRS)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+am__relativize = \
+ dir0=`pwd`; \
+ sed_first='s,^\([^/]*\)/.*$$,\1,'; \
+ sed_rest='s,^[^/]*/*,,'; \
+ sed_last='s,^.*/\([^/]*\)$$,\1,'; \
+ sed_butlast='s,/*[^/]*$$,,'; \
+ while test -n "$$dir1"; do \
+ first=`echo "$$dir1" | sed -e "$$sed_first"`; \
+ if test "$$first" != "."; then \
+ if test "$$first" = ".."; then \
+ dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \
+ dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \
+ else \
+ first2=`echo "$$dir2" | sed -e "$$sed_first"`; \
+ if test "$$first2" = "$$first"; then \
+ dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \
+ else \
+ dir2="../$$dir2"; \
+ fi; \
+ dir0="$$dir0"/"$$first"; \
+ fi; \
+ fi; \
+ dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \
+ done; \
+ reldir="$$dir2"
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+SUBDIRS = route genl
+EXTRA_DIST = \
+ capi.i \
+ fixes.h \
+ __init__.py \
+ core.py \
+ util.py \
+ utils.h
+
+all: all-recursive
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/netlink/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/netlink/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+# This directory's subdirectories are mostly independent; you can cd
+# into them and run 'make' without going through this Makefile.
+# To change the values of 'make' variables: instead of editing Makefiles,
+# (1) if the variable is set in 'config.status', edit 'config.status'
+# (which will cause the Makefiles to be regenerated when you run 'make');
+# (2) otherwise, pass the desired values on the 'make' command line.
+$(am__recursive_targets):
+ @fail=; \
+ if $(am__make_keepgoing); then \
+ failcom='fail=yes'; \
+ else \
+ failcom='exit 1'; \
+ fi; \
+ dot_seen=no; \
+ target=`echo $@ | sed s/-recursive//`; \
+ case "$@" in \
+ distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \
+ *) list='$(SUBDIRS)' ;; \
+ esac; \
+ for subdir in $$list; do \
+ echo "Making $$target in $$subdir"; \
+ if test "$$subdir" = "."; then \
+ dot_seen=yes; \
+ local_target="$$target-am"; \
+ else \
+ local_target="$$target"; \
+ fi; \
+ ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \
+ || eval $$failcom; \
+ done; \
+ if test "$$dot_seen" = "no"; then \
+ $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
+ fi; test -z "$$fail"
+
+ID: $(am__tagged_files)
+ $(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+ set x; \
+ here=`pwd`; \
+ if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
+ include_option=--etags-include; \
+ empty_fix=.; \
+ else \
+ include_option=--include; \
+ empty_fix=; \
+ fi; \
+ list='$(SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ test ! -f $$subdir/TAGS || \
+ set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
+ fi; \
+ done; \
+ $(am__define_uniq_tagged_files); \
+ shift; \
+ if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ if test $$# -gt 0; then \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ "$$@" $$unique; \
+ else \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$unique; \
+ fi; \
+ fi
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+ $(am__define_uniq_tagged_files); \
+ test -z "$(CTAGS_ARGS)$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && $(am__cd) $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive
+
+cscopelist-am: $(am__tagged_files)
+ list='$(am__tagged_files)'; \
+ case "$(srcdir)" in \
+ [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
+ *) sdir=$(subdir)/$(srcdir) ;; \
+ esac; \
+ for i in $$list; do \
+ if test -f "$$i"; then \
+ echo "$(subdir)/$$i"; \
+ else \
+ echo "$$sdir/$$i"; \
+ fi; \
+ done >> $(top_builddir)/cscope.files
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+ @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
+ if test "$$subdir" = .; then :; else \
+ $(am__make_dryrun) \
+ || test -d "$(distdir)/$$subdir" \
+ || $(MKDIR_P) "$(distdir)/$$subdir" \
+ || exit 1; \
+ dir1=$$subdir; dir2="$(distdir)/$$subdir"; \
+ $(am__relativize); \
+ new_distdir=$$reldir; \
+ dir1=$$subdir; dir2="$(top_distdir)"; \
+ $(am__relativize); \
+ new_top_distdir=$$reldir; \
+ echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \
+ echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \
+ ($(am__cd) $$subdir && \
+ $(MAKE) $(AM_MAKEFLAGS) \
+ top_distdir="$$new_top_distdir" \
+ distdir="$$new_distdir" \
+ am__remove_distdir=: \
+ am__skip_length_check=: \
+ am__skip_mode_fix=: \
+ distdir) \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-recursive
+all-am: Makefile
+installdirs: installdirs-recursive
+installdirs-am:
+install: install-recursive
+install-exec: install-exec-recursive
+install-data: install-data-recursive
+uninstall: uninstall-recursive
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-recursive
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-recursive
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-recursive
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic distclean-tags
+
+dvi: dvi-recursive
+
+dvi-am:
+
+html: html-recursive
+
+html-am:
+
+info: info-recursive
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-recursive
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-recursive
+
+install-html-am:
+
+install-info: install-info-recursive
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-recursive
+
+install-pdf-am:
+
+install-ps: install-ps-recursive
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-recursive
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-recursive
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-recursive
+
+pdf-am:
+
+ps: ps-recursive
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: $(am__recursive_targets) install-am install-strip
+
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
+ check-am clean clean-generic clean-libtool cscopelist-am ctags \
+ ctags-am distclean distclean-generic distclean-libtool \
+ distclean-tags distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ installdirs-am maintainer-clean maintainer-clean-generic \
+ mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
+ ps ps-am tags tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/__init__.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/__init__.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/capi.i b/ap/lib/libnl/libnl-3.2.25/python/netlink/capi.i
new file mode 100644
index 0000000..e5d8a53
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/capi.i
@@ -0,0 +1,964 @@
+%module capi
+%{
+#include <netlink/netlink.h>
+#include <netlink/types.h>
+#include <netlink/socket.h>
+#include <netlink/msg.h>
+#include <netlink/object.h>
+#include <netlink/cache.h>
+#include <netlink/attr.h>
+#include <net/if.h>
+
+#define DEBUG
+#include "utils.h"
+%}
+
+%include <stdint.i>
+%include <cstring.i>
+%include <cpointer.i>
+
+%inline %{
+ struct nl_dump_params *alloc_dump_params(void)
+ {
+ struct nl_dump_params *dp;
+ if (!(dp = calloc(1, sizeof(*dp))))
+ return NULL;
+ dp->dp_fd = stdout;
+ return dp;
+ }
+
+ void free_dump_params(struct nl_dump_params *dp)
+ {
+ free(dp);
+ }
+%};
+
+/* <netlink/types.h> */
+
+enum nl_dump_type {
+ NL_DUMP_LINE, /**< Dump object briefly on one line */
+ NL_DUMP_DETAILS, /**< Dump all attributes but no statistics */
+ NL_DUMP_STATS, /**< Dump all attributes including statistics */
+ __NL_DUMP_MAX,
+};
+
+struct nl_dump_params
+{
+ /**
+ * Specifies the type of dump that is requested.
+ */
+ enum nl_dump_type dp_type;
+
+ /**
+ * Specifies the number of whitespaces to be put in front
+ * of every new line (indentation).
+ */
+ int dp_prefix;
+
+ /**
+ * Causes the cache index to be printed for each element.
+ */
+ int dp_print_index;
+
+ /**
+ * Causes each element to be prefixed with the message type.
+ */
+ int dp_dump_msgtype;
+
+ /**
+ * A callback invoked for output
+ *
+ * Passed arguments are:
+ * - dumping parameters
+ * - string to append to the output
+ */
+ void (*dp_cb)(struct nl_dump_params *, char *);
+
+ /**
+ * A callback invoked for every new line, can be used to
+ * customize the indentation.
+ *
+ * Passed arguments are:
+ * - dumping parameters
+ * - line number starting from 0
+ */
+ void (*dp_nl_cb)(struct nl_dump_params *, int);
+
+ /**
+ * User data pointer, can be used to pass data to callbacks.
+ */
+ void *dp_data;
+
+ /**
+ * File descriptor the dumping output should go to
+ */
+ FILE * dp_fd;
+
+ /**
+ * Alternatively the output may be redirected into a buffer
+ */
+ char * dp_buf;
+
+ /**
+ * Length of the buffer dp_buf
+ */
+ size_t dp_buflen;
+
+ /**
+ * PRIVATE
+ * Set if a dump was performed prior to the actual dump handler.
+ */
+ int dp_pre_dump;
+
+ /**
+ * PRIVATE
+ * Owned by the current caller
+ */
+ int dp_ivar;
+
+ unsigned int dp_line;
+};
+
+/* <net/if.h> */
+extern unsigned int if_nametoindex(const char *ifname);
+
+/* <netlink/errno.h> */
+extern const char *nl_geterror(int);
+
+/* <netlink/utils.h> */
+
+extern double nl_cancel_down_bytes(unsigned long long, char **);
+extern double nl_cancel_down_bits(unsigned long long, char **);
+%cstring_output_maxsize(char *buf, size_t len)
+extern int nl_rate2str(unsigned long long rate, int type, char *buf, size_t len);
+extern double nl_cancel_down_us(uint32_t, char **);
+
+extern long nl_size2int(const char *);
+%cstring_output_maxsize(char *buf, const size_t len)
+extern char *nl_size2str(const size_t, char *buf, const size_t len);
+extern long nl_prob2int(const char *);
+
+extern int nl_get_user_hz(void);
+extern uint32_t nl_us2ticks(uint32_t);
+extern uint32_t nl_ticks2us(uint32_t);
+extern int nl_str2msec(const char *, uint64_t *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_msec2str(uint64_t, char *buf, size_t len);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_llproto2str(int, char *buf, size_t len);
+extern int nl_str2llproto(const char *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_ether_proto2str(int, char *buf, size_t len);
+extern int nl_str2ether_proto(const char *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_ip_proto2str(int, char *buf, size_t len);
+extern int nl_str2ip_proto(const char *);
+
+extern void nl_new_line(struct nl_dump_params *);
+extern void nl_dump(struct nl_dump_params *, const char *, ...);
+extern void nl_dump_line(struct nl_dump_params *, const char *, ...);
+
+/* <netlink/netlink.h> */
+extern struct nl_dump_params *alloc_dump_params(void);
+extern void free_dump_params(struct nl_dump_params *);
+
+extern int nl_connect(struct nl_sock *, int);
+extern void nl_close(struct nl_sock *);
+
+/* <netlink/socket.h> */
+extern struct nl_sock *nl_socket_alloc(void);
+extern struct nl_sock *nl_socket_alloc_cb(struct nl_cb *);
+extern void nl_socket_free(struct nl_sock *);
+
+extern uint32_t nl_socket_get_local_port(const struct nl_sock *);
+extern void nl_socket_set_local_port(struct nl_sock *, uint32_t);
+
+extern uint32_t nl_socket_get_peer_port(const struct nl_sock *);
+extern void nl_socket_set_peer_port(struct nl_sock *, uint32_t);
+
+extern uint32_t nl_socket_get_peer_groups(const struct nl_sock *sk);
+extern void nl_socket_set_peer_groups(struct nl_sock *sk, uint32_t groups);
+
+extern int nl_socket_set_buffer_size(struct nl_sock *, int, int);
+extern void nl_socket_set_cb(struct nl_sock *, struct nl_cb *);
+
+extern int nl_send_auto_complete(struct nl_sock *, struct nl_msg *);
+extern int nl_recvmsgs(struct nl_sock *, struct nl_cb *);
+
+/* <netlink/msg.h> */
+extern int nlmsg_size(int);
+extern int nlmsg_total_size(int);
+extern int nlmsg_padlen(int);
+
+extern void * nlmsg_data(const struct nlmsghdr *);
+extern int nlmsg_datalen(const struct nlmsghdr *);
+extern void * nlmsg_tail(const struct nlmsghdr *);
+
+/* attribute access */
+extern struct nlattr * nlmsg_attrdata(const struct nlmsghdr *, int);
+extern int nlmsg_attrlen(const struct nlmsghdr *, int);
+
+/* message parsing */
+extern int nlmsg_valid_hdr(const struct nlmsghdr *, int);
+extern int nlmsg_ok(const struct nlmsghdr *, int);
+extern struct nlmsghdr * nlmsg_next(struct nlmsghdr *, int *);
+extern int nlmsg_parse(struct nlmsghdr *, int, struct nlattr **,
+ int, struct nla_policy *);
+extern struct nlattr * nlmsg_find_attr(struct nlmsghdr *, int, int);
+extern int nlmsg_validate(struct nlmsghdr *, int, int,
+ struct nla_policy *);
+
+extern struct nl_msg * nlmsg_alloc(void);
+extern struct nl_msg * nlmsg_alloc_size(size_t);
+extern struct nl_msg * nlmsg_alloc_simple(int, int);
+extern void nlmsg_set_default_size(size_t);
+extern struct nl_msg * nlmsg_inherit(struct nlmsghdr *);
+extern struct nl_msg * nlmsg_convert(struct nlmsghdr *);
+extern void * nlmsg_reserve(struct nl_msg *, size_t, int);
+extern int nlmsg_append(struct nl_msg *, void *, size_t, int);
+extern int nlmsg_expand(struct nl_msg *, size_t);
+
+extern struct nlmsghdr * nlmsg_put(struct nl_msg *, uint32_t, uint32_t,
+ int, int, int);
+extern struct nlmsghdr * nlmsg_hdr(struct nl_msg *);
+extern void nlmsg_get(struct nl_msg *);
+extern void nlmsg_free(struct nl_msg *);
+
+/* attribute modification */
+extern void nlmsg_set_proto(struct nl_msg *, int);
+extern int nlmsg_get_proto(struct nl_msg *);
+extern size_t nlmsg_get_max_size(struct nl_msg *);
+extern void nlmsg_set_src(struct nl_msg *, struct sockaddr_nl *);
+extern struct sockaddr_nl *nlmsg_get_src(struct nl_msg *);
+extern void nlmsg_set_dst(struct nl_msg *, struct sockaddr_nl *);
+extern struct sockaddr_nl *nlmsg_get_dst(struct nl_msg *);
+extern void nlmsg_set_creds(struct nl_msg *, struct ucred *);
+extern struct ucred * nlmsg_get_creds(struct nl_msg *);
+
+extern char * nl_nlmsgtype2str(int, char *, size_t);
+extern int nl_str2nlmsgtype(const char *);
+
+extern char * nl_nlmsg_flags2str(int, char *, size_t);
+
+extern int nl_msg_parse(struct nl_msg *,
+ void (*cb)(struct nl_object *, void *),
+ void *);
+
+extern void nl_msg_dump(struct nl_msg *, FILE *);
+
+%inline %{
+ struct nl_object *cast_obj(void *obj)
+ {
+ return (struct nl_object *) obj;
+ }
+
+ struct nl_object *object_alloc_name(const char *name)
+ {
+ struct nl_object *obj;
+
+ if (nl_object_alloc_name(name, &obj) < 0)
+ return NULL;
+
+ return obj;
+ }
+%};
+
+extern struct nl_object *nl_object_alloc(struct nl_object_ops *);
+extern void nl_object_free(struct nl_object *);
+extern struct nl_object *nl_object_clone(struct nl_object *);
+extern void nl_object_get(struct nl_object *);
+extern void nl_object_put(struct nl_object *);
+extern int nl_object_shared(struct nl_object *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern void nl_object_dump_buf(struct nl_object *, char *buf, size_t len);
+
+extern void nl_object_dump(struct nl_object *, struct nl_dump_params *);
+
+extern int nl_object_identical(struct nl_object *, struct nl_object *);
+extern uint32_t nl_object_diff(struct nl_object *, struct nl_object *);
+extern int nl_object_match_filter(struct nl_object *, struct nl_object *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_object_attrs2str(struct nl_object *, uint32_t, char *buf, size_t len);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_object_attr_list(struct nl_object *, char *buf, size_t len);
+
+extern void nl_object_mark(struct nl_object *);
+extern void nl_object_unmark(struct nl_object *);
+extern int nl_object_is_marked(struct nl_object *);
+
+extern int nl_object_get_refcnt(struct nl_object *);
+
+/* <netlink/cache.h> */
+
+typedef void (*change_func_t)(struct nl_cache *, struct nl_object *, int, void *);
+
+%inline %{
+ struct nl_cache *alloc_cache_name(const char *name)
+ {
+ struct nl_cache *c;
+ if (nl_cache_alloc_name(name, &c) < 0)
+ return NULL;
+ return c;
+ }
+
+ struct nl_cache_mngr *alloc_cache_mngr(struct nl_sock *sock,
+ int protocol, int flags)
+ {
+ struct nl_cache_mngr *mngr;
+
+ if (nl_cache_mngr_alloc(sock, protocol, flags, &mngr) < 0)
+ return NULL;
+
+ return mngr;
+ }
+
+ struct nl_cache *cache_mngr_add(struct nl_cache_mngr *mngr,
+ const char *name, change_func_t func,
+ void *arg)
+ {
+ struct nl_cache *cache;
+
+ if (nl_cache_mngr_add(mngr, name, func, arg, &cache) < 0)
+ return NULL;
+
+ return cache;
+ }
+%}
+
+/* Access Functions */
+extern int nl_cache_nitems(struct nl_cache *);
+extern int nl_cache_nitems_filter(struct nl_cache *,
+ struct nl_object *);
+extern struct nl_cache_ops * nl_cache_get_ops(struct nl_cache *);
+extern struct nl_object * nl_cache_get_first(struct nl_cache *);
+extern struct nl_object * nl_cache_get_last(struct nl_cache *);
+extern struct nl_object * nl_cache_get_next(struct nl_object *);
+extern struct nl_object * nl_cache_get_prev(struct nl_object *);
+
+extern struct nl_cache * nl_cache_alloc(struct nl_cache_ops *);
+extern struct nl_cache * nl_cache_subset(struct nl_cache *,
+ struct nl_object *);
+extern void nl_cache_clear(struct nl_cache *);
+extern void nl_cache_free(struct nl_cache *);
+
+/* Cache modification */
+extern int nl_cache_add(struct nl_cache *,
+ struct nl_object *);
+extern int nl_cache_parse_and_add(struct nl_cache *,
+ struct nl_msg *);
+extern void nl_cache_remove(struct nl_object *);
+extern int nl_cache_refill(struct nl_sock *,
+ struct nl_cache *);
+extern int nl_cache_pickup(struct nl_sock *,
+ struct nl_cache *);
+extern int nl_cache_resync(struct nl_sock *,
+ struct nl_cache *,
+ change_func_t,
+ void *);
+extern int nl_cache_include(struct nl_cache *,
+ struct nl_object *,
+ change_func_t,
+ void *);
+extern void nl_cache_set_arg1(struct nl_cache *, int);
+extern void nl_cache_set_arg2(struct nl_cache *, int);
+
+/* General */
+extern int nl_cache_is_empty(struct nl_cache *);
+extern struct nl_object * nl_cache_search(struct nl_cache *,
+ struct nl_object *);
+extern void nl_cache_mark_all(struct nl_cache *);
+
+/* Dumping */
+extern void nl_cache_dump(struct nl_cache *,
+ struct nl_dump_params *);
+extern void nl_cache_dump_filter(struct nl_cache *,
+ struct nl_dump_params *,
+ struct nl_object *);
+
+/* Iterators */
+extern void nl_cache_foreach(struct nl_cache *,
+ void (*cb)(struct nl_object *,
+ void *),
+ void *arg);
+extern void nl_cache_foreach_filter(struct nl_cache *,
+ struct nl_object *,
+ void (*cb)(struct
+ nl_object *,
+ void *),
+ void *arg);
+
+/* --- cache management --- */
+
+/* Cache type management */
+extern struct nl_cache_ops * nl_cache_ops_lookup(const char *);
+extern struct nl_cache_ops * nl_cache_ops_associate(int, int);
+extern struct nl_msgtype * nl_msgtype_lookup(struct nl_cache_ops *, int);
+extern void nl_cache_ops_foreach(void (*cb)(struct nl_cache_ops *, void *), void *);
+extern int nl_cache_mngt_register(struct nl_cache_ops *);
+extern int nl_cache_mngt_unregister(struct nl_cache_ops *);
+
+/* Global cache provisioning/requiring */
+extern void nl_cache_mngt_provide(struct nl_cache *);
+extern void nl_cache_mngt_unprovide(struct nl_cache *);
+extern struct nl_cache * nl_cache_mngt_require(const char *);
+
+struct nl_cache_mngr;
+
+#define NL_AUTO_PROVIDE 1
+
+extern int nl_cache_mngr_get_fd(struct nl_cache_mngr *);
+extern int nl_cache_mngr_poll(struct nl_cache_mngr *,
+ int);
+extern int nl_cache_mngr_data_ready(struct nl_cache_mngr *);
+extern void nl_cache_mngr_free(struct nl_cache_mngr *);
+
+/* <netlink/addr.h> */
+%inline %{
+ struct nl_addr *addr_parse(const char *addr, int guess)
+ {
+ struct nl_addr *result;
+
+ if (nl_addr_parse(addr, guess, &result) < 0)
+ return NULL;
+
+ return result;
+ }
+%};
+
+extern struct nl_addr *nl_addr_alloc(size_t);
+extern struct nl_addr *nl_addr_alloc_attr(struct nlattr *, int);
+extern struct nl_addr *nl_addr_build(int, void *, size_t);
+extern struct nl_addr *nl_addr_clone(struct nl_addr *);
+
+extern struct nl_addr *nl_addr_get(struct nl_addr *);
+extern void nl_addr_put(struct nl_addr *);
+extern int nl_addr_shared(struct nl_addr *);
+
+extern int nl_addr_cmp(struct nl_addr *, struct nl_addr *);
+extern int nl_addr_cmp_prefix(struct nl_addr *, struct nl_addr *);
+extern int nl_addr_iszero(struct nl_addr *);
+extern int nl_addr_valid(char *, int);
+extern int nl_addr_guess_family(struct nl_addr *);
+extern int nl_addr_fill_sockaddr(struct nl_addr *, struct sockaddr *, socklen_t *);
+extern int nl_addr_info(struct nl_addr *, struct addrinfo **);
+extern int nl_addr_resolve(struct nl_addr *addr, char *host, size_t hostlen);
+
+extern void nl_addr_set_family(struct nl_addr *, int);
+extern int nl_addr_get_family(struct nl_addr *);
+extern int nl_addr_set_binary_addr(struct nl_addr *, void *, size_t);
+
+extern void *nl_addr_get_binary_addr(struct nl_addr *);
+extern unsigned int nl_addr_get_len(struct nl_addr *);
+extern void nl_addr_set_prefixlen(struct nl_addr *, int);
+extern unsigned int nl_addr_get_prefixlen(struct nl_addr *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_af2str(int, char *buf, size_t len);
+extern int nl_str2af(const char *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *nl_addr2str(struct nl_addr *, char *buf, size_t len);
+
+/* Message Handlers <netlink/handlers.h> */
+/**
+ * Callback actions
+ * @ingroup cb
+ */
+enum nl_cb_action {
+ /** Proceed with wathever would come next */
+ NL_OK,
+ /** Skip this message */
+ NL_SKIP,
+ /** Stop parsing altogether and discard remaining messages */
+ NL_STOP,
+};
+
+/**
+ * Callback kinds
+ * @ingroup cb
+ */
+enum nl_cb_kind {
+ /** Default handlers (quiet) */
+ NL_CB_DEFAULT,
+ /** Verbose default handlers (error messages printed) */
+ NL_CB_VERBOSE,
+ /** Debug handlers for debugging */
+ NL_CB_DEBUG,
+ /** Customized handler specified by the user */
+ NL_CB_CUSTOM,
+ __NL_CB_KIND_MAX,
+};
+
+#define NL_CB_KIND_MAX (__NL_CB_KIND_MAX - 1)
+
+/**
+ * Callback types
+ * @ingroup cb
+ */
+enum nl_cb_type {
+ /** Message is valid */
+ NL_CB_VALID,
+ /** Last message in a series of multi part messages received */
+ NL_CB_FINISH,
+ /** Report received that data was lost */
+ NL_CB_OVERRUN,
+ /** Message wants to be skipped */
+ NL_CB_SKIPPED,
+ /** Message is an acknowledge */
+ NL_CB_ACK,
+ /** Called for every message received */
+ NL_CB_MSG_IN,
+ /** Called for every message sent out except for nl_sendto() */
+ NL_CB_MSG_OUT,
+ /** Message is malformed and invalid */
+ NL_CB_INVALID,
+ /** Called instead of internal sequence number checking */
+ NL_CB_SEQ_CHECK,
+ /** Sending of an acknowledge message has been requested */
+ NL_CB_SEND_ACK,
+ /** Flag NLM_F_DUMP_INTR is set in message */
+ NL_CB_DUMP_INTR,
+ __NL_CB_TYPE_MAX,
+};
+
+#define NL_CB_TYPE_MAX (__NL_CB_TYPE_MAX - 1)
+
+extern struct nl_cb *nl_cb_alloc(enum nl_cb_kind);
+extern struct nl_cb *nl_cb_clone(struct nl_cb *);
+
+struct nlmsgerr {
+ int error;
+};
+
+%{
+
+struct pynl_callback {
+ PyObject *cbf;
+ PyObject *cba;
+};
+
+struct pynl_cbinfo {
+ struct nl_cb *cb;
+ struct pynl_callback cbtype[NL_CB_TYPE_MAX+1];
+ struct pynl_callback cberr;
+ struct list_head list;
+};
+
+LIST_HEAD(callback_list);
+
+static struct pynl_cbinfo *pynl_find_cbinfo(struct nl_cb *cb, int unlink)
+{
+ struct list_head *pos, *prev;
+ struct pynl_cbinfo *info;
+
+ list_for_each_safe(pos, prev, &callback_list) {
+ info = container_of(pos, struct pynl_cbinfo, list);
+ if (info->cb == cb) {
+ if (unlink)
+ list_del(pos, prev);
+ pynl_dbg("cb=%p: found=%p\n", cb, info);
+ return info;
+ }
+ }
+ pynl_dbg("cb=%p: not found\n", cb);
+ return NULL;
+}
+
+static struct pynl_cbinfo *pynl_get_cbinfo(struct nl_cb *cb, int unlink)
+{
+ struct pynl_cbinfo *info;
+
+ info = pynl_find_cbinfo(cb, unlink);
+
+ if (info || unlink) {
+ /* found or no need to allocate a new one */
+ pynl_dbg("cb=%p: done\n", cb);
+ return info;
+ }
+
+ info = calloc(1, sizeof(*info));
+ info->cb = cb;
+ list_add(&info->list, &callback_list);
+ pynl_dbg("cb=%p: added %p\n", cb, info);
+ return info;
+}
+
+static int nl_recv_msg_handler(struct nl_msg *msg, void *arg)
+{
+ struct pynl_callback *cbd = arg;
+ PyObject *msgobj;
+ PyObject *cbparobj;
+ PyObject *resobj;
+ PyObject *funcobj;
+ int result;
+
+ if (!cbd) {
+ result = NL_STOP;
+ goto done;
+ }
+ msgobj = SWIG_NewPointerObj(SWIG_as_voidptr(msg),
+ SWIGTYPE_p_nl_msg, 0 | 0 );
+ /* add selfobj if callback is a method */
+ if (cbd->cbf && PyMethod_Check(cbd->cbf)) {
+ PyObject *selfobj = PyMethod_Self(cbd->cbf);
+ cbparobj = Py_BuildValue("(OOO)", selfobj ? selfobj : cbd->cba,
+ msgobj, cbd->cba);
+ funcobj = PyMethod_Function(cbd->cbf);
+ pynl_dbg("callback %sbounded instance method %p\n",
+ selfobj ? "" : "un", funcobj);
+ } else {
+ cbparobj = Py_BuildValue("(OO)", msgobj, cbd->cba);
+ funcobj = cbd->cbf;
+ pynl_dbg("callback function %p\n", funcobj);
+ }
+ resobj = PyObject_CallObject(funcobj, cbparobj);
+ Py_DECREF(cbparobj);
+ if (resobj && PyInt_Check(resobj))
+ result = (int)PyInt_AsLong(resobj);
+ else
+ result = NL_STOP;
+ Py_XDECREF(resobj);
+done:
+ pynl_dbg("result=%d\n", result);
+ return result;
+}
+
+static int nl_recv_err_handler(struct sockaddr_nl *nla, struct nlmsgerr *err,
+ void *arg)
+{
+ struct pynl_callback *cbd = arg;
+ PyObject *errobj;
+ PyObject *cbparobj;
+ PyObject *resobj;
+ PyObject *funcobj;
+ int result;
+
+ if (!cbd)
+ return NL_STOP;
+ errobj = SWIG_NewPointerObj(SWIG_as_voidptr(err),
+ SWIGTYPE_p_nlmsgerr, 0 | 0 );
+ /* add selfobj if callback is a method */
+ if (cbd->cbf && PyMethod_Check(cbd->cbf)) {
+ PyObject *selfobj = PyMethod_Self(cbd->cbf);
+ cbparobj = Py_BuildValue("(OOO)", selfobj ? selfobj : cbd->cba,
+ errobj, cbd->cba);
+ funcobj = PyMethod_Function(cbd->cbf);
+ } else {
+ cbparobj = Py_BuildValue("(OO)", errobj, cbd->cba);
+ funcobj = cbd->cbf;
+ }
+ resobj = PyObject_CallObject(funcobj, cbparobj);
+ Py_DECREF(cbparobj);
+ if (resobj && PyInt_Check(resobj))
+ result = (int)PyInt_AsLong(resobj);
+ else
+ result = NL_STOP;
+ Py_XDECREF(resobj);
+ pynl_dbg("error: err=%d ret=%d\n", err->error, result);
+ return result;
+}
+
+%}
+%inline %{
+struct nl_cb *py_nl_cb_clone(struct nl_cb *cb)
+{
+ struct pynl_cbinfo *info, *clone_info;
+ struct nl_cb *clone;
+ int i;
+
+ clone = nl_cb_clone(cb);
+ info = pynl_find_cbinfo(cb, 0);
+ if (info) {
+ clone_info = pynl_get_cbinfo(clone, 0);
+ /* increase refcnt to callback parameters and copy them */
+ for (i = 0; info && i <= NL_CB_TYPE_MAX; i++) {
+ Py_XINCREF(info->cbtype[i].cbf);
+ Py_XINCREF(info->cbtype[i].cba);
+ clone_info->cbtype[i].cbf = info->cbtype[i].cbf;
+ clone_info->cbtype[i].cba = info->cbtype[i].cba;
+ }
+ Py_XINCREF(info->cberr.cbf);
+ Py_XINCREF(info->cberr.cba);
+ clone_info->cberr.cbf = info->cberr.cbf;
+ clone_info->cberr.cba = info->cberr.cba;
+ }
+ return clone;
+}
+
+void py_nl_cb_put(struct nl_cb *cb)
+{
+ struct pynl_cbinfo *info;
+ int i;
+
+ /* obtain callback info (and unlink) */
+ info = pynl_get_cbinfo(cb, 1);
+ pynl_dbg("cb=%p, info=%p\n", cb, info);
+ /* decrease refcnt for callback type handlers */
+ for (i = 0; info && i <= NL_CB_TYPE_MAX; i++) {
+ Py_XDECREF(info->cbtype[i].cbf);
+ Py_XDECREF(info->cbtype[i].cba);
+ }
+ /* decrease refcnt for error handler and free callback info */
+ if (info) {
+ Py_XDECREF(info->cberr.cbf);
+ Py_XDECREF(info->cberr.cba);
+ free(info);
+ }
+ nl_cb_put(cb);
+}
+
+int py_nl_cb_set(struct nl_cb *cb, enum nl_cb_type t, enum nl_cb_kind k,
+ PyObject *func, PyObject *a)
+{
+ struct pynl_cbinfo *info;
+
+ /* obtain callback info */
+ info = pynl_get_cbinfo(cb, 0);
+
+ /* clear existing handlers (if any) */
+ Py_XDECREF(info->cbtype[t].cbf);
+ Py_XDECREF(info->cbtype[t].cba);
+ info->cbtype[t].cbf = NULL;
+ info->cbtype[t].cba = NULL;
+ pynl_dbg("cb=%p, info=%p, type=%d, kind=%d\n", cb, info, t, k);
+ /* handle custom callback */
+ if (k == NL_CB_CUSTOM) {
+ Py_XINCREF(func);
+ Py_XINCREF(a);
+ info->cbtype[t].cbf = func;
+ info->cbtype[t].cba = a;
+ return nl_cb_set(cb, t, k,
+ nl_recv_msg_handler, &info->cbtype[t]);
+ }
+ return nl_cb_set(cb, t, k, NULL, NULL);
+}
+
+int py_nl_cb_set_all(struct nl_cb *cb, enum nl_cb_kind k,
+ PyObject *func , PyObject *a)
+{
+ struct pynl_cbinfo *info;
+ int t;
+
+ info = pynl_get_cbinfo(cb, 0);
+ pynl_dbg("cb=%p, info=%p, kind=%d\n", cb, info, k);
+ for (t = 0; t <= NL_CB_TYPE_MAX; t++) {
+ /* (possibly) free existing handler */
+ Py_XDECREF(info->cbtype[t].cbf);
+ Py_XDECREF(info->cbtype[t].cba);
+ info->cbtype[t].cbf = NULL;
+ info->cbtype[t].cba = NULL;
+ if (k == NL_CB_CUSTOM) {
+ Py_XINCREF(func);
+ Py_XINCREF(a);
+ info->cbtype[t].cbf = func;
+ info->cbtype[t].cba = a;
+ }
+ }
+ if (k == NL_CB_CUSTOM)
+ /* callback argument is same for all so using idx 0 here */
+ return nl_cb_set_all(cb, k, nl_recv_msg_handler,
+ &info->cbtype[0]);
+ else
+ return nl_cb_set_all(cb, k, NULL, NULL);
+}
+
+int py_nl_cb_err(struct nl_cb *cb, enum nl_cb_kind k,
+ PyObject *func, PyObject *a)
+{
+ struct pynl_cbinfo *info;
+
+ /* obtain callback info */
+ info = pynl_get_cbinfo(cb, 0);
+ pynl_dbg("cb=%p, info=%p, kind=%d\n", cb, info, k);
+ /* clear existing handlers (if any) */
+ Py_XDECREF(info->cberr.cbf);
+ Py_XDECREF(info->cberr.cba);
+ info->cberr.cbf = NULL;
+ info->cberr.cba = NULL;
+
+ /* handle custom callback */
+ if (k == NL_CB_CUSTOM) {
+ Py_XINCREF(func);
+ Py_XINCREF(a);
+ info->cberr.cbf = func;
+ info->cberr.cba = a;
+ return nl_cb_err(cb, k,
+ nl_recv_err_handler, &info->cberr);
+ }
+ return nl_cb_err(cb, k, NULL, NULL);
+}
+%}
+
+/* Attributes <netlink/attr.h> */
+/*
+ * This typemap is a bit tricky as it uses arg1, which is knowledge about
+ * the SWIGged wrapper output.
+ */
+%typemap(out) void * {
+ $result = PyByteArray_FromStringAndSize($1, nla_len(arg1));
+}
+extern void *nla_data(struct nlattr *);
+%typemap(out) void *;
+extern int nla_type(const struct nlattr *);
+
+/* Integer attribute */
+extern uint8_t nla_get_u8(struct nlattr *);
+extern int nla_put_u8(struct nl_msg *, int, uint8_t);
+extern uint16_t nla_get_u16(struct nlattr *);
+extern int nla_put_u16(struct nl_msg *, int, uint16_t);
+extern uint32_t nla_get_u32(struct nlattr *);
+extern int nla_put_u32(struct nl_msg *, int, uint32_t);
+extern uint64_t nla_get_u64(struct nlattr *);
+extern int nla_put_u64(struct nl_msg *, int, uint64_t);
+
+/* String attribute */
+extern char * nla_get_string(struct nlattr *);
+extern char * nla_strdup(struct nlattr *);
+extern int nla_put_string(struct nl_msg *, int, const char *);
+
+/* Flag attribute */
+extern int nla_get_flag(struct nlattr *);
+extern int nla_put_flag(struct nl_msg *, int);
+
+/* Msec attribute */
+extern unsigned long nla_get_msecs(struct nlattr *);
+extern int nla_put_msecs(struct nl_msg *, int, unsigned long);
+
+/* Attribute nesting */
+extern int nla_put_nested(struct nl_msg *, int, struct nl_msg *);
+extern struct nlattr * nla_nest_start(struct nl_msg *, int);
+extern int nla_nest_end(struct nl_msg *, struct nlattr *);
+%inline %{
+PyObject *py_nla_parse_nested(int max, struct nlattr *nest_attr, PyObject *p)
+{
+ struct nlattr *tb_msg[max + 1];
+ struct nla_policy *policy = NULL;
+ void *pol;
+ PyObject *attrs = Py_None;
+ PyObject *k;
+ PyObject *v;
+ PyObject *resobj;
+ int err;
+ int i;
+
+ if (p != Py_None) {
+ PyObject *pobj;
+
+ if (!PyList_Check(p)) {
+ fprintf(stderr, "expected list object\n");
+ err = -1;
+ goto fail;
+ }
+ pobj = PyList_GetItem(p, 0);
+ err = SWIG_ConvertPtr(pobj, &pol, SWIGTYPE_p_nla_policy, 0 | 0 );
+ if (!SWIG_IsOK(err))
+ goto fail;
+ policy = pol;
+ }
+ err = nla_parse_nested(tb_msg, max, nest_attr, policy);
+ if (err < 0) {
+ fprintf(stderr, "Failed to parse response message\n");
+ } else {
+ attrs = PyDict_New();
+ for (i = 0; i <= max; i++)
+ if (tb_msg[i]) {
+ k = PyInt_FromLong((long)i);
+ v = SWIG_NewPointerObj(SWIG_as_voidptr(tb_msg[i]), SWIGTYPE_p_nlattr, 0 | 0 );
+ PyDict_SetItem(attrs, k, v);
+ }
+ }
+fail:
+ if (attrs == Py_None)
+ Py_INCREF(attrs);
+ resobj = Py_BuildValue("(iO)", err, attrs);
+ return resobj;
+}
+
+/*
+ * nla_get_nested() - get list of nested attributes.
+ *
+ * nla_for_each_<nested|attr>() is a macro construct that needs another approach
+ * for Python. Create and return list of nested attributes.
+ */
+PyObject *nla_get_nested(struct nlattr *nest_attr)
+{
+ PyObject *listobj;
+ PyObject *nestattrobj;
+ struct nlattr *pos;
+ int rem;
+
+ listobj = PyList_New(0);
+ nla_for_each_nested(pos, nest_attr, rem) {
+ nestattrobj = SWIG_NewPointerObj(SWIG_as_voidptr(pos),
+ SWIGTYPE_p_nlattr, 0 | 0 );
+ PyList_Append(listobj, nestattrobj);
+ }
+ return listobj;
+}
+%}
+
+ /**
+ * @ingroup attr
+ * Basic attribute data types
+ *
+ * See \ref attr_datatypes for more details.
+ */
+enum {
+ NLA_UNSPEC, /**< Unspecified type, binary data chunk */
+ NLA_U8, /**< 8 bit integer */
+ NLA_U16, /**< 16 bit integer */
+ NLA_U32, /**< 32 bit integer */
+ NLA_U64, /**< 64 bit integer */
+ NLA_STRING, /**< NUL terminated character string */
+ NLA_FLAG, /**< Flag */
+ NLA_MSECS, /**< Micro seconds (64bit) */
+ NLA_NESTED, /**< Nested attributes */
+ __NLA_TYPE_MAX,
+};
+
+#define NLA_TYPE_MAX (__NLA_TYPE_MAX - 1)
+
+/** @} */
+
+/**
+ * @ingroup attr
+ * Attribute validation policy.
+ *
+ * See \ref attr_datatypes for more details.
+ */
+struct nla_policy {
+ /** Type of attribute or NLA_UNSPEC */
+ uint16_t type;
+
+ /** Minimal length of payload required */
+ uint16_t minlen;
+
+ /** Maximal length of payload allowed */
+ uint16_t maxlen;
+};
+
+%inline %{
+PyObject *nla_policy_array(int n_items)
+{
+ struct nla_policy *policies;
+ PyObject *listobj;
+ PyObject *polobj;
+ int i;
+
+ policies = calloc(n_items, sizeof(*policies));
+ listobj = PyList_New(n_items);
+ for (i = 0; i < n_items; i++) {
+ polobj = SWIG_NewPointerObj(SWIG_as_voidptr(&policies[i]),
+ SWIGTYPE_p_nla_policy, 0 | 0 );
+ PyList_SetItem(listobj, i, polobj);
+ }
+ return listobj;
+}
+%}
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/core.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/core.py
new file mode 100644
index 0000000..e5864cf
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/core.py
@@ -0,0 +1,793 @@
+#
+# Netlink interface based on libnl
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""netlink library based on libnl
+
+This module provides an interface to netlink sockets
+
+The module contains the following public classes:
+ - Socket -- The netlink socket
+ - Message -- The netlink message
+ - Callback -- The netlink callback handler
+ - Object -- Abstract object (based on struct nl_obect in libnl) used as
+ base class for all object types which can be put into a Cache
+ - Cache -- A collection of objects which are derived from the base
+ class Object. Used for netlink protocols which maintain a list
+ or tree of objects.
+ - DumpParams --
+
+The following exceptions are defined:
+ - NetlinkError -- Base exception for all general purpose exceptions raised.
+ - KernelError -- Raised when the kernel returns an error as response to a
+ request.
+
+All other classes or functions in this module are considered implementation
+details.
+"""
+from __future__ import absolute_import
+
+
+
+from . import capi
+import sys
+import socket
+
+__all__ = [
+ 'Socket',
+ 'Message',
+ 'Callback',
+ 'DumpParams',
+ 'Object',
+ 'Cache',
+ 'KernelError',
+ 'NetlinkError',
+]
+
+__version__ = '0.1'
+
+# netlink protocols
+NETLINK_ROUTE = 0
+# NETLINK_UNUSED = 1
+NETLINK_USERSOCK = 2
+NETLINK_FIREWALL = 3
+NETLINK_INET_DIAG = 4
+NETLINK_NFLOG = 5
+NETLINK_XFRM = 6
+NETLINK_SELINUX = 7
+NETLINK_ISCSI = 8
+NETLINK_AUDIT = 9
+NETLINK_FIB_LOOKUP = 10
+NETLINK_CONNECTOR = 11
+NETLINK_NETFILTER = 12
+NETLINK_IP6_FW = 13
+NETLINK_DNRTMSG = 14
+NETLINK_KOBJECT_UEVENT = 15
+NETLINK_GENERIC = 16
+NETLINK_SCSITRANSPORT = 18
+NETLINK_ECRYPTFS = 19
+
+NL_DONTPAD = 0
+NL_AUTO_PORT = 0
+NL_AUTO_SEQ = 0
+
+NL_DUMP_LINE = 0
+NL_DUMP_DETAILS = 1
+NL_DUMP_STATS = 2
+
+NLM_F_REQUEST = 1
+NLM_F_MULTI = 2
+NLM_F_ACK = 4
+NLM_F_ECHO = 8
+
+NLM_F_ROOT = 0x100
+NLM_F_MATCH = 0x200
+NLM_F_ATOMIC = 0x400
+NLM_F_DUMP = NLM_F_ROOT | NLM_F_MATCH
+
+NLM_F_REPLACE = 0x100
+NLM_F_EXCL = 0x200
+NLM_F_CREATE = 0x400
+NLM_F_APPEND = 0x800
+
+class NetlinkError(Exception):
+ def __init__(self, error):
+ self._error = error
+ self._msg = capi.nl_geterror(error)
+
+ def __str__(self):
+ return self._msg
+
+class KernelError(NetlinkError):
+ def __str__(self):
+ return 'Kernel returned: {0}'.format(self._msg)
+
+class ImmutableError(NetlinkError):
+ def __init__(self, msg):
+ self._msg = msg
+
+ def __str__(self):
+ return 'Immutable attribute: {0}'.format(self._msg)
+
+class Message(object):
+ """Netlink message"""
+
+ def __init__(self, size=0):
+ if size == 0:
+ self._msg = capi.nlmsg_alloc()
+ else:
+ self._msg = capi.nlmsg_alloc_size(size)
+
+ if self._msg is None:
+ raise Exception('Message allocation returned NULL')
+
+ def __del__(self):
+ capi.nlmsg_free(self._msg)
+
+ def __len__(self):
+ return capi.nlmsg_len(nlmsg_hdr(self._msg))
+
+ @property
+ def protocol(self):
+ return capi.nlmsg_get_proto(self._msg)
+
+ @protocol.setter
+ def protocol(self, value):
+ capi.nlmsg_set_proto(self._msg, value)
+
+ @property
+ def maxSize(self):
+ return capi.nlmsg_get_max_size(self._msg)
+
+ @property
+ def hdr(self):
+ return capi.nlmsg_hdr(self._msg)
+
+ @property
+ def data(self):
+ return capi.nlmsg_data(self._msg)
+
+ @property
+ def attrs(self):
+ return capi.nlmsg_attrdata(self._msg)
+
+ def send(self, sock):
+ sock.send(self)
+
+class Callback(object):
+ """Netlink callback"""
+
+ def __init__(self, kind=capi.NL_CB_DEFAULT):
+ if isinstance(kind, Callback):
+ self._cb = capi.py_nl_cb_clone(kind._cb)
+ else:
+ self._cb = capi.nl_cb_alloc(kind)
+
+ def __del__(self):
+ capi.py_nl_cb_put(self._cb)
+
+ def set_type(self, t, k, handler, obj):
+ return capi.py_nl_cb_set(self._cb, t, k, handler, obj)
+
+ def set_all(self, k, handler, obj):
+ return capi.py_nl_cb_set_all(self._cb, k, handler, obj)
+
+ def set_err(self, k, handler, obj):
+ return capi.py_nl_cb_err(self._cb, k, handler, obj)
+
+ def clone(self):
+ return Callback(self)
+
+class Socket(object):
+ """Netlink socket"""
+
+ def __init__(self, cb=None):
+ if isinstance(cb, Callback):
+ self._sock = capi.nl_socket_alloc_cb(cb._cb)
+ elif cb == None:
+ self._sock = capi.nl_socket_alloc()
+ else:
+ raise Exception('\'cb\' parameter has wrong type')
+
+ if self._sock is None:
+ raise Exception('NULL pointer returned while allocating socket')
+
+ def __del__(self):
+ capi.nl_socket_free(self._sock)
+
+ def __str__(self):
+ return 'nlsock<{0}>'.format(self.local_port)
+
+ @property
+ def local_port(self):
+ return capi.nl_socket_get_local_port(self._sock)
+
+ @local_port.setter
+ def local_port(self, value):
+ capi.nl_socket_set_local_port(self._sock, int(value))
+
+ @property
+ def peer_port(self):
+ return capi.nl_socket_get_peer_port(self._sock)
+
+ @peer_port.setter
+ def peer_port(self, value):
+ capi.nl_socket_set_peer_port(self._sock, int(value))
+
+ @property
+ def peer_groups(self):
+ return capi.nl_socket_get_peer_groups(self._sock)
+
+ @peer_groups.setter
+ def peer_groups(self, value):
+ capi.nl_socket_set_peer_groups(self._sock, value)
+
+ def set_bufsize(self, rx, tx):
+ capi.nl_socket_set_buffer_size(self._sock, rx, tx)
+
+ def connect(self, proto):
+ capi.nl_connect(self._sock, proto)
+ return self
+
+ def disconnect(self):
+ capi.nl_close(self._sock)
+
+ def sendto(self, buf):
+ ret = capi.nl_sendto(self._sock, buf, len(buf))
+ if ret < 0:
+ raise Exception('Failed to send')
+ else:
+ return ret
+
+ def send_auto_complete(self, msg):
+ if not isinstance(msg, Message):
+ raise Exception('must provide Message instance')
+ ret = capi.nl_send_auto_complete(self._sock, msg._msg)
+ if ret < 0:
+ raise Exception('send_auto_complete failed: ret=%d' % ret)
+ return ret
+
+ def recvmsgs(self, recv_cb):
+ if not isinstance(recv_cb, Callback):
+ raise Exception('must provide Callback instance')
+ ret = capi.nl_recvmsgs(self._sock, recv_cb._cb)
+ if ret < 0:
+ raise Exception('recvmsg failed: ret=%d' % ret)
+
+_sockets = {}
+
+def lookup_socket(protocol):
+ try:
+ sock = _sockets[protocol]
+ except KeyError:
+ sock = Socket()
+ sock.connect(protocol)
+ _sockets[protocol] = sock
+
+ return sock
+
+class DumpParams(object):
+ """Dumping parameters"""
+
+ def __init__(self, type_=NL_DUMP_LINE):
+ self._dp = capi.alloc_dump_params()
+ if not self._dp:
+ raise Exception('Unable to allocate struct nl_dump_params')
+
+ self._dp.dp_type = type_
+
+ def __del__(self):
+ capi.free_dump_params(self._dp)
+
+ @property
+ def type(self):
+ return self._dp.dp_type
+
+ @type.setter
+ def type(self, value):
+ self._dp.dp_type = value
+
+ @property
+ def prefix(self):
+ return self._dp.dp_prefix
+
+ @prefix.setter
+ def prefix(self, value):
+ self._dp.dp_prefix = value
+
+# underscore this to make sure it is deleted first upon module deletion
+_defaultDumpParams = DumpParams(NL_DUMP_LINE)
+
+class Object(object):
+ """Cacheable object (base class)"""
+
+ def __init__(self, obj_name, name, obj=None):
+ self._obj_name = obj_name
+ self._name = name
+ self._modules = []
+
+ if not obj:
+ obj = capi.object_alloc_name(self._obj_name)
+
+ self._nl_object = obj
+
+ # Create a clone which stores the original state to notice
+ # modifications
+ clone_obj = capi.nl_object_clone(self._nl_object)
+ self._orig = self._obj2type(clone_obj)
+
+ def __del__(self):
+ if not self._nl_object:
+ raise ValueError()
+
+ capi.nl_object_put(self._nl_object)
+
+ def __str__(self):
+ if hasattr(self, 'format'):
+ return self.format()
+ else:
+ return capi.nl_object_dump_buf(self._nl_object, 4096).rstrip()
+
+ def _new_instance(self):
+ raise NotImplementedError()
+
+ def clone(self):
+ """Clone object"""
+ return self._new_instance(capi.nl_object_clone(self._nl_object))
+
+ def _module_lookup(self, path, constructor=None):
+ """Lookup object specific module and load it
+
+ Object implementations consisting of multiple types may
+ offload some type specific code to separate modules which
+ are loadable on demand, e.g. a VLAN link or a specific
+ queueing discipline implementation.
+
+ Loads the module `path` and calls the constructor if
+ supplied or `module`.init()
+
+ The constructor/init function typically assigns a new
+ object covering the type specific implementation aspects
+ to the new object, e.g. link.vlan = VLANLink()
+ """
+ try:
+ __import__(path)
+ except ImportError:
+ return
+
+ module = sys.modules[path]
+
+ if constructor:
+ ret = getattr(module, constructor)(self)
+ else:
+ ret = module.init(self)
+
+ if ret:
+ self._modules.append(ret)
+
+ def _module_brief(self):
+ ret = ''
+
+ for module in self._modules:
+ if hasattr(module, 'brief'):
+ ret += module.brief()
+
+ return ret
+
+ def dump(self, params=None):
+ """Dump object as human readable text"""
+ if params is None:
+ params = _defaultDumpParams
+
+ capi.nl_object_dump(self._nl_object, params._dp)
+
+
+ @property
+ def mark(self):
+ return bool(capi.nl_object_is_marked(self._nl_object))
+
+ @mark.setter
+ def mark(self, value):
+ if value:
+ capi.nl_object_mark(self._nl_object)
+ else:
+ capi.nl_object_unmark(self._nl_object)
+
+ @property
+ def shared(self):
+ return capi.nl_object_shared(self._nl_object) != 0
+
+ @property
+ def attrs(self):
+ attr_list = capi.nl_object_attr_list(self._nl_object, 1024)
+ return attr_list[0].split()
+
+ @property
+ def refcnt(self):
+ return capi.nl_object_get_refcnt(self._nl_object)
+
+ # this method resolves multiple levels of sub types to allow
+ # accessing properties of subclass/subtypes (e.g. link.vlan.id)
+ def _resolve(self, attr):
+ obj = self
+ l = attr.split('.')
+ while len(l) > 1:
+ obj = getattr(obj, l.pop(0))
+ return (obj, l.pop(0))
+
+ def _setattr(self, attr, val):
+ obj, attr = self._resolve(attr)
+ return setattr(obj, attr, val)
+
+ def _hasattr(self, attr):
+ obj, attr = self._resolve(attr)
+ return hasattr(obj, attr)
+
+class ObjIterator(object):
+ def __init__(self, cache, obj):
+ self._cache = cache
+ self._nl_object = None
+
+ if not obj:
+ self._end = 1
+ else:
+ capi.nl_object_get(obj)
+ self._nl_object = obj
+ self._first = 1
+ self._end = 0
+
+ def __del__(self):
+ if self._nl_object:
+ capi.nl_object_put(self._nl_object)
+
+ def __iter__(self):
+ return self
+
+ def get_next(self):
+ return capi.nl_cache_get_next(self._nl_object)
+
+ def next(self):
+ return self.__next__()
+
+ def __next__(self):
+ if self._end:
+ raise StopIteration()
+
+ if self._first:
+ ret = self._nl_object
+ self._first = 0
+ else:
+ ret = self.get_next()
+ if not ret:
+ self._end = 1
+ raise StopIteration()
+
+ # return ref of previous element and acquire ref of current
+ # element to have object stay around until we fetched the
+ # next ptr
+ capi.nl_object_put(self._nl_object)
+ capi.nl_object_get(ret)
+ self._nl_object = ret
+
+ # reference used inside object
+ capi.nl_object_get(ret)
+ return self._cache._new_object(ret)
+
+
+class ReverseObjIterator(ObjIterator):
+ def get_next(self):
+ return capi.nl_cache_get_prev(self._nl_object)
+
+class Cache(object):
+ """Collection of netlink objects"""
+ def __init__(self):
+ if self.__class__ is Cache:
+ raise NotImplementedError()
+ self.arg1 = None
+ self.arg2 = None
+
+ def __del__(self):
+ capi.nl_cache_free(self._nl_cache)
+
+ def __len__(self):
+ return capi.nl_cache_nitems(self._nl_cache)
+
+ def __iter__(self):
+ obj = capi.nl_cache_get_first(self._nl_cache)
+ return ObjIterator(self, obj)
+
+ def __reversed__(self):
+ obj = capi.nl_cache_get_last(self._nl_cache)
+ return ReverseObjIterator(self, obj)
+
+ def __contains__(self, item):
+ obj = capi.nl_cache_search(self._nl_cache, item._nl_object)
+ if obj is None:
+ return False
+ else:
+ capi.nl_object_put(obj)
+ return True
+
+ # called by sub classes to allocate type specific caches by name
+ @staticmethod
+ def _alloc_cache_name(name):
+ return capi.alloc_cache_name(name)
+
+ # implemented by sub classes, must return new instasnce of cacheable
+ # object
+ @staticmethod
+ def _new_object(obj):
+ raise NotImplementedError()
+
+ # implemented by sub classes, must return instance of sub class
+ def _new_cache(self, cache):
+ raise NotImplementedError()
+
+ def subset(self, filter_):
+ """Return new cache containing subset of cache
+
+ Cretes a new cache containing all objects which match the
+ specified filter.
+ """
+ if not filter_:
+ raise ValueError()
+
+ c = capi.nl_cache_subset(self._nl_cache, filter_._nl_object)
+ return self._new_cache(cache=c)
+
+ def dump(self, params=None, filter_=None):
+ """Dump (print) cache as human readable text"""
+ if not params:
+ params = _defaultDumpParams
+
+ if filter_:
+ filter_ = filter_._nl_object
+
+ capi.nl_cache_dump_filter(self._nl_cache, params._dp, filter_)
+
+ def clear(self):
+ """Remove all cache entries"""
+ capi.nl_cache_clear(self._nl_cache)
+
+ # Called by sub classes to set first cache argument
+ def _set_arg1(self, arg):
+ self.arg1 = arg
+ capi.nl_cache_set_arg1(self._nl_cache, arg)
+
+ # Called by sub classes to set second cache argument
+ def _set_arg2(self, arg):
+ self.arg2 = arg
+ capi.nl_cache_set_arg2(self._nl_cache, arg)
+
+ def refill(self, socket=None):
+ """Clear cache and refill it"""
+ if socket is None:
+ socket = lookup_socket(self._protocol)
+
+ capi.nl_cache_refill(socket._sock, self._nl_cache)
+ return self
+
+ def resync(self, socket=None, cb=None, args=None):
+ """Synchronize cache with content in kernel"""
+ if socket is None:
+ socket = lookup_socket(self._protocol)
+
+ capi.nl_cache_resync(socket._sock, self._nl_cache, cb, args)
+
+ def provide(self):
+ """Provide this cache to others
+
+ Caches which have been "provided" are made available
+ to other users (of the same application context) which
+ "require" it. F.e. a link cache is generally provided
+ to allow others to translate interface indexes to
+ link names
+ """
+
+ capi.nl_cache_mngt_provide(self._nl_cache)
+
+ def unprovide(self):
+ """Unprovide this cache
+
+ No longer make the cache available to others. If the cache
+ has been handed out already, that reference will still
+ be valid.
+ """
+ capi.nl_cache_mngt_unprovide(self._nl_cache)
+
+# Cache Manager (Work in Progress)
+NL_AUTO_PROVIDE = 1
+class CacheManager(object):
+ def __init__(self, protocol, flags=None):
+
+ self._sock = Socket()
+ self._sock.connect(protocol)
+
+ if not flags:
+ flags = NL_AUTO_PROVIDE
+
+ self._mngr = capi.cache_mngr_alloc(self._sock._sock, protocol, flags)
+
+ def __del__(self):
+ if self._sock:
+ self._sock.disconnect()
+
+ if self._mngr:
+ capi.nl_cache_mngr_free(self._mngr)
+
+ def add(self, name):
+ capi.cache_mngr_add(self._mngr, name, None, None)
+
+class AddressFamily(object):
+ """Address family representation
+
+ af = AddressFamily('inet6')
+ # raises:
+ # - ValueError if family name is not known
+ # - TypeError if invalid type is specified for family
+
+ print af # => 'inet6' (string representation)
+ print int(af) # => 10 (numeric representation)
+ print repr(af) # => AddressFamily('inet6')
+ """
+ def __init__(self, family=socket.AF_UNSPEC):
+ if isinstance(family, str):
+ family = capi.nl_str2af(family)
+ if family < 0:
+ raise ValueError('Unknown family name')
+ elif not isinstance(family, int):
+ raise TypeError()
+
+ self._family = family
+
+ def __str__(self):
+ return capi.nl_af2str(self._family, 32)[0]
+
+ def __int__(self):
+ return self._family
+
+ def __repr__(self):
+ return 'AddressFamily({0!r})'.format(str(self))
+
+
+class AbstractAddress(object):
+ """Abstract address object
+
+ addr = AbstractAddress('127.0.0.1/8')
+ print addr # => '127.0.0.1/8'
+ print addr.prefixlen # => '8'
+ print addr.family # => 'inet'
+ print len(addr) # => '4' (32bit ipv4 address)
+
+ a = AbstractAddress('10.0.0.1/24')
+ b = AbstractAddress('10.0.0.2/24')
+ print a == b # => False
+
+
+ """
+ def __init__(self, addr):
+ self._nl_addr = None
+
+ if isinstance(addr, str):
+ # returns None on success I guess
+ # TO CORRECT
+ addr = capi.addr_parse(addr, socket.AF_UNSPEC)
+ if addr is None:
+ raise ValueError('Invalid address format')
+ elif addr:
+ capi.nl_addr_get(addr)
+
+ self._nl_addr = addr
+
+ def __del__(self):
+ if self._nl_addr:
+ capi.nl_addr_put(self._nl_addr)
+
+ def __cmp__(self, other):
+ if isinstance(other, str):
+ other = AbstractAddress(other)
+
+ diff = self.prefixlen - other.prefixlen
+ if diff == 0:
+ diff = capi.nl_addr_cmp(self._nl_addr, other._nl_addr)
+
+ return diff
+
+ def contains(self, item):
+ diff = int(self.family) - int(item.family)
+ if diff:
+ return False
+
+ if item.prefixlen < self.prefixlen:
+ return False
+
+ diff = capi.nl_addr_cmp_prefix(self._nl_addr, item._nl_addr)
+ return diff == 0
+
+ def __nonzero__(self):
+ if self._nl_addr:
+ return not capi.nl_addr_iszero(self._nl_addr)
+ else:
+ return False
+
+ def __len__(self):
+ if self._nl_addr:
+ return capi.nl_addr_get_len(self._nl_addr)
+ else:
+ return 0
+
+ def __str__(self):
+ if self._nl_addr:
+ return capi.nl_addr2str(self._nl_addr, 64)[0]
+ else:
+ return 'none'
+
+ @property
+ def shared(self):
+ """True if address is shared (multiple users)"""
+ if self._nl_addr:
+ return capi.nl_addr_shared(self._nl_addr) != 0
+ else:
+ return False
+
+ @property
+ def prefixlen(self):
+ """Length of prefix (number of bits)"""
+ if self._nl_addr:
+ return capi.nl_addr_get_prefixlen(self._nl_addr)
+ else:
+ return 0
+
+ @prefixlen.setter
+ def prefixlen(self, value):
+ if not self._nl_addr:
+ raise TypeError()
+
+ capi.nl_addr_set_prefixlen(self._nl_addr, int(value))
+
+ @property
+ def family(self):
+ """Address family"""
+ f = 0
+ if self._nl_addr:
+ f = capi.nl_addr_get_family(self._nl_addr)
+
+ return AddressFamily(f)
+
+ @family.setter
+ def family(self, value):
+ if not self._nl_addr:
+ raise TypeError()
+
+ if not isinstance(value, AddressFamily):
+ value = AddressFamily(value)
+
+ capi.nl_addr_set_family(self._nl_addr, int(value))
+
+
+# keyword:
+# type = { int | str }
+# immutable = { True | False }
+# fmt = func (formatting function)
+# title = string
+
+def nlattr(**kwds):
+ """netlink object attribute decorator
+
+ decorator used to mark mutable and immutable properties
+ of netlink objects. All properties marked as such are
+ regarded to be accessable.
+
+ @property
+ @netlink.nlattr(type=int)
+ def my_attr(self):
+ return self._my_attr
+
+ """
+
+ def wrap_fn(func):
+ func.formatinfo = kwds
+ return func
+ return wrap_fn
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/fixes.h b/ap/lib/libnl/libnl-3.2.25/python/netlink/fixes.h
new file mode 100644
index 0000000..9a6118b
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/fixes.h
@@ -0,0 +1 @@
+#include <stdint.h>
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/Makefile.am
new file mode 100644
index 0000000..9e30904
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/Makefile.am
@@ -0,0 +1,5 @@
+# -*- Makefile -*-
+
+EXTRA_DIST = \
+ capi.i \
+ __init__.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/Makefile.in
new file mode 100644
index 0000000..bd80e2d
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/Makefile.in
@@ -0,0 +1,443 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python/netlink/genl
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+ capi.i \
+ __init__.py
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/netlink/genl/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/netlink/genl/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags TAGS:
+
+ctags CTAGS:
+
+cscope cscopelist:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ cscopelist-am ctags-am distclean distclean-generic \
+ distclean-libtool distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/__init__.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/__init__.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/capi.i b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/capi.i
new file mode 100644
index 0000000..069e617
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/genl/capi.i
@@ -0,0 +1,108 @@
+%module capi
+%{
+#include <netlink/genl/ctrl.h>
+#include <netlink/genl/family.h>
+#include <netlink/genl/genl.h>
+#include <netlink/genl/mngt.h>
+%}
+
+%include <stdint.i>
+%include <cstring.i>
+
+/* #include <netlink/genl/ctrl.h> */
+extern int genl_ctrl_alloc_cache(struct nl_sock *, struct nl_cache **o_cache);
+extern struct genl_family *genl_ctrl_search(struct nl_cache *, int);
+extern struct genl_family *genl_ctrl_search_by_name(struct nl_cache *,
+ const char *);
+extern int genl_ctrl_resolve(struct nl_sock *, const char *);
+extern int genl_ctrl_resolve_grp(struct nl_sock *sk, const char *family,
+ const char *grp);
+
+/* #include <netlink/genl/family.h> */
+extern struct genl_family *genl_family_alloc(void);
+extern void genl_family_put(struct genl_family *);
+
+extern unsigned int genl_family_get_id(struct genl_family *);
+extern void genl_family_set_id(struct genl_family *, unsigned int);
+extern char *genl_family_get_name(struct genl_family *);
+extern void genl_family_set_name(struct genl_family *, const char *name);
+extern uint8_t genl_family_get_version(struct genl_family *);
+extern void genl_family_set_version(struct genl_family *, uint8_t);
+extern uint32_t genl_family_get_hdrsize(struct genl_family *);
+extern void genl_family_set_hdrsize(struct genl_family *, uint32_t);
+extern uint32_t genl_family_get_maxattr(struct genl_family *);
+extern void genl_family_set_maxattr(struct genl_family *, uint32_t);
+
+extern int genl_family_add_op(struct genl_family *, int, int);
+extern int genl_family_add_grp(struct genl_family *, uint32_t , const char *);
+
+/* #include <netlink/genl/genl.h> */
+extern int genl_connect(struct nl_sock *);
+
+extern void *genlmsg_put(struct nl_msg *, uint32_t, uint32_t,
+ int, int, int, uint8_t, uint8_t);
+
+struct nlattr {
+};
+
+struct nla_policy {
+ /** Type of attribute or NLA_UNSPEC */
+ uint16_t type;
+
+ /** Minimal length of payload required */
+ uint16_t minlen;
+
+ /** Maximal length of payload allowed */
+ uint16_t maxlen;
+};
+
+%inline %{
+PyObject *py_genlmsg_parse(struct nlmsghdr *nlh, int uhl, int max,
+ PyObject *p)
+{
+ struct nlattr *tb_msg[max + 1];
+ struct nla_policy *policy = NULL;
+ void *pol;
+ PyObject *attrs = Py_None;
+ PyObject *k;
+ PyObject *v;
+ PyObject *resobj;
+ int err;
+ int i;
+
+ if (p != Py_None) {
+ PyObject *pobj;
+
+ if (!PyList_Check(p)) {
+ fprintf(stderr, "expected list object\n");
+ err = -1;
+ goto fail;
+ }
+ pobj = PyList_GetItem(p, 0);
+ err = SWIG_ConvertPtr(pobj, &pol, SWIGTYPE_p_nla_policy, 0 | 0 );
+ if (!SWIG_IsOK(err))
+ goto fail;
+ policy = pol;
+ }
+ err = genlmsg_parse(nlh, uhl, tb_msg, max, policy);
+ if (err < 0) {
+ fprintf(stderr, "Failed to parse response message\n");
+ } else {
+ attrs = PyDict_New();
+ for (i = 0; i <= max; i++)
+ if (tb_msg[i]) {
+ k = PyInt_FromLong((long)i);
+ v = SWIG_NewPointerObj(SWIG_as_voidptr(tb_msg[i]), SWIGTYPE_p_nlattr, 0 | 0 );
+ PyDict_SetItem(attrs, k, v);
+ }
+ }
+fail:
+ if (attrs == Py_None)
+ Py_INCREF(Py_None);
+ resobj = Py_BuildValue("(iO)", err, attrs);
+ return resobj;
+}
+
+%}
+/* #include <netlink/genl/mngt.h> */
+/* nothing yet */
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/Makefile.am
new file mode 100644
index 0000000..ef714f4
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/Makefile.am
@@ -0,0 +1,14 @@
+# -*- Makefile -*-
+
+EXTRA_DIST = \
+ capi.i \
+ __init__.py \
+ address.py \
+ link.py \
+ tc.py \
+ links/__init__.py \
+ links/dummy.py \
+ links/inet.py \
+ links/vlan.py \
+ qdisc/__init__.py \
+ qdisc/htb.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/Makefile.in
new file mode 100644
index 0000000..2c56123
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/Makefile.in
@@ -0,0 +1,452 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python/netlink/route
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+ capi.i \
+ __init__.py \
+ address.py \
+ link.py \
+ tc.py \
+ links/__init__.py \
+ links/dummy.py \
+ links/inet.py \
+ links/vlan.py \
+ qdisc/__init__.py \
+ qdisc/htb.py
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/netlink/route/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/netlink/route/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags TAGS:
+
+ctags CTAGS:
+
+cscope cscopelist:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ cscopelist-am ctags-am distclean distclean-generic \
+ distclean-libtool distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/__init__.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/__init__.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/address.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/address.py
new file mode 100644
index 0000000..cab2a97
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/address.py
@@ -0,0 +1,367 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""Module providing access to network addresses
+"""
+
+from __future__ import absolute_import
+
+
+__version__ = '1.0'
+__all__ = [
+ 'AddressCache',
+ 'Address']
+
+import datetime
+from .. import core as netlink
+from . import capi as capi
+from . import link as Link
+from .. import util as util
+
+class AddressCache(netlink.Cache):
+ """Cache containing network addresses"""
+
+ def __init__(self, cache=None):
+ if not cache:
+ cache = self._alloc_cache_name('route/addr')
+
+ self._protocol = netlink.NETLINK_ROUTE
+ self._nl_cache = cache
+
+ def __getitem__(self, key):
+ # Using ifindex=0 here implies that the local address itself
+ # is unique, otherwise the first occurence is returned.
+ return self.lookup(0, key)
+
+ def lookup(self, ifindex, local):
+ if type(local) is str:
+ local = netlink.AbstractAddress(local)
+
+ addr = capi.rtnl_addr_get(self._nl_cache, ifindex,
+ local._nl_addr)
+ if addr is None:
+ raise KeyError()
+
+ return Address._from_capi(addr)
+
+ @staticmethod
+ def _new_object(obj):
+ return Address(obj)
+
+ @staticmethod
+ def _new_cache(cache):
+ return AddressCache(cache=cache)
+
+class Address(netlink.Object):
+ """Network address"""
+
+ def __init__(self, obj=None):
+ netlink.Object.__init__(self, 'route/addr', 'address', obj)
+ self._rtnl_addr = self._obj2type(self._nl_object)
+
+ @classmethod
+ def _from_capi(cls, obj):
+ return cls(capi.addr2obj(obj))
+
+ @staticmethod
+ def _obj2type(obj):
+ return capi.obj2addr(obj)
+
+ def __cmp__(self, other):
+ # sort by:
+ # 1. network link
+ # 2. address family
+ # 3. local address (including prefixlen)
+ diff = self.ifindex - other.ifindex
+
+ if diff == 0:
+ diff = self.family - other.family
+ if diff == 0:
+ diff = capi.nl_addr_cmp(self.local, other.local)
+
+ return diff
+
+ @staticmethod
+ def _new_instance(obj):
+ return Address(obj)
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def ifindex(self):
+ """interface index"""
+ return capi.rtnl_addr_get_ifindex(self._rtnl_addr)
+
+ @ifindex.setter
+ def ifindex(self, value):
+ link = Link.resolve(value)
+ if not link:
+ raise ValueError()
+
+ self.link = link
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.string)
+ def link(self):
+ link = capi.rtnl_addr_get_link(self._rtnl_addr)
+ if not link:
+ return None
+
+ return Link.Link.from_capi(link)
+
+ @link.setter
+ def link(self, value):
+ if type(value) is str:
+ try:
+ value = Link.resolve(value)
+ except KeyError:
+ raise ValueError()
+
+ capi.rtnl_addr_set_link(self._rtnl_addr, value._rtnl_link)
+
+ # ifindex is immutable but we assume that if _orig does not
+ # have an ifindex specified, it was meant to be given here
+ if capi.rtnl_addr_get_ifindex(self._orig) == 0:
+ capi.rtnl_addr_set_ifindex(self._orig, value.ifindex)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.string)
+ def label(self):
+ """address label"""
+ return capi.rtnl_addr_get_label(self._rtnl_addr)
+
+ @label.setter
+ def label(self, value):
+ capi.rtnl_addr_set_label(self._rtnl_addr, value)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.string)
+ def flags(self):
+ """Flags
+
+ Setting this property will *Not* reset flags to value you supply in
+
+ Examples:
+ addr.flags = '+xxx' # add xxx flag
+ addr.flags = 'xxx' # exactly the same
+ addr.flags = '-xxx' # remove xxx flag
+ addr.flags = [ '+xxx', '-yyy' ] # list operation
+ """
+ flags = capi.rtnl_addr_get_flags(self._rtnl_addr)
+ return capi.rtnl_addr_flags2str(flags, 256)[0].split(',')
+
+ def _set_flag(self, flag):
+ if flag.startswith('-'):
+ i = capi.rtnl_addr_str2flags(flag[1:])
+ capi.rtnl_addr_unset_flags(self._rtnl_addr, i)
+ elif flag.startswith('+'):
+ i = capi.rtnl_addr_str2flags(flag[1:])
+ capi.rtnl_addr_set_flags(self._rtnl_addr, i)
+ else:
+ i = capi.rtnl_addr_str2flags(flag)
+ capi.rtnl_addr_set_flags(self._rtnl_addr, i)
+
+ @flags.setter
+ def flags(self, value):
+ if type(value) is list:
+ for flag in value:
+ self._set_flag(flag)
+ else:
+ self._set_flag(value)
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def family(self):
+ """Address family"""
+ fam = capi.rtnl_addr_get_family(self._rtnl_addr)
+ return netlink.AddressFamily(fam)
+
+ @family.setter
+ def family(self, value):
+ if not isinstance(value, netlink.AddressFamily):
+ value = netlink.AddressFamily(value)
+
+ capi.rtnl_addr_set_family(self._rtnl_addr, int(value))
+
+ @property
+ @netlink.nlattr(type=int, fmt=util.num)
+ def scope(self):
+ """Address scope"""
+ scope = capi.rtnl_addr_get_scope(self._rtnl_addr)
+ return capi.rtnl_scope2str(scope, 32)[0]
+
+ @scope.setter
+ def scope(self, value):
+ if type(value) is str:
+ value = capi.rtnl_str2scope(value)
+ capi.rtnl_addr_set_scope(self._rtnl_addr, value)
+
+ @property
+ @netlink.nlattr(type=str, immutable=True, fmt=util.addr)
+ def local(self):
+ """Local address"""
+ a = capi.rtnl_addr_get_local(self._rtnl_addr)
+ return netlink.AbstractAddress(a)
+
+ @local.setter
+ def local(self, value):
+ a = netlink.AbstractAddress(value)
+ capi.rtnl_addr_set_local(self._rtnl_addr, a._nl_addr)
+
+ # local is immutable but we assume that if _orig does not
+ # have a local address specified, it was meant to be given here
+ if capi.rtnl_addr_get_local(self._orig) is None:
+ capi.rtnl_addr_set_local(self._orig, a._nl_addr)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.addr)
+ def peer(self):
+ """Peer address"""
+ a = capi.rtnl_addr_get_peer(self._rtnl_addr)
+ return netlink.AbstractAddress(a)
+
+ @peer.setter
+ def peer(self, value):
+ a = netlink.AbstractAddress(value)
+ capi.rtnl_addr_set_peer(self._rtnl_addr, a._nl_addr)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.addr)
+ def broadcast(self):
+ """Broadcast address"""
+ a = capi.rtnl_addr_get_broadcast(self._rtnl_addr)
+ return netlink.AbstractAddress(a)
+
+ @broadcast.setter
+ def broadcast(self, value):
+ a = netlink.AbstractAddress(value)
+ capi.rtnl_addr_set_broadcast(self._rtnl_addr, a._nl_addr)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.addr)
+ def multicast(self):
+ """multicast address"""
+ a = capi.rtnl_addr_get_multicast(self._rtnl_addr)
+ return netlink.AbstractAddress(a)
+
+ @multicast.setter
+ def multicast(self, value):
+ try:
+ a = netlink.AbstractAddress(value)
+ except ValueError as err:
+ raise AttributeError('multicast', err)
+
+ capi.rtnl_addr_set_multicast(self._rtnl_addr, a._nl_addr)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.addr)
+ def anycast(self):
+ """anycast address"""
+ a = capi.rtnl_addr_get_anycast(self._rtnl_addr)
+ return netlink.AbstractAddress(a)
+
+ @anycast.setter
+ def anycast(self, value):
+ a = netlink.AbstractAddress(value)
+ capi.rtnl_addr_set_anycast(self._rtnl_addr, a._nl_addr)
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def valid_lifetime(self):
+ """Valid lifetime"""
+ msecs = capi.rtnl_addr_get_valid_lifetime(self._rtnl_addr)
+ if msecs == 0xFFFFFFFF:
+ return None
+ else:
+ return datetime.timedelta(seconds=msecs)
+
+ @valid_lifetime.setter
+ def valid_lifetime(self, value):
+ capi.rtnl_addr_set_valid_lifetime(self._rtnl_addr, int(value))
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def preferred_lifetime(self):
+ """Preferred lifetime"""
+ msecs = capi.rtnl_addr_get_preferred_lifetime(self._rtnl_addr)
+ if msecs == 0xFFFFFFFF:
+ return None
+ else:
+ return datetime.timedelta(seconds=msecs)
+
+ @preferred_lifetime.setter
+ def preferred_lifetime(self, value):
+ capi.rtnl_addr_set_preferred_lifetime(self._rtnl_addr, int(value))
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def create_time(self):
+ """Creation time"""
+ hsec = capi.rtnl_addr_get_create_time(self._rtnl_addr)
+ return datetime.timedelta(milliseconds=10*hsec)
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def last_update(self):
+ """Last update"""
+ hsec = capi.rtnl_addr_get_last_update_time(self._rtnl_addr)
+ return datetime.timedelta(milliseconds=10*hsec)
+
+ def add(self, socket=None, flags=None):
+ if not socket:
+ socket = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ if not flags:
+ flags = netlink.NLM_F_CREATE
+
+ ret = capi.rtnl_addr_add(socket._sock, self._rtnl_addr, flags)
+ if ret < 0:
+ raise netlink.KernelError(ret)
+
+ def delete(self, socket, flags=0):
+ """Attempt to delete this address in the kernel"""
+ ret = capi.rtnl_addr_delete(socket._sock, self._rtnl_addr, flags)
+ if ret < 0:
+ raise netlink.KernelError(ret)
+
+ ###################################################################
+ # private properties
+ #
+ # Used for formatting output. USE AT OWN RISK
+ @property
+ def _flags(self):
+ return ','.join(self.flags)
+
+ def format(self, details=False, stats=False, nodev=False, indent=''):
+ """Return address as formatted text"""
+ fmt = util.MyFormatter(self, indent)
+
+ buf = fmt.format('{a|local!b}')
+
+ if not nodev:
+ buf += fmt.format(' {a|ifindex}')
+
+ buf += fmt.format(' {a|scope}')
+
+ if self.label:
+ buf += fmt.format(' "{a|label}"')
+
+ buf += fmt.format(' <{a|_flags}>')
+
+ if details:
+ buf += fmt.nl('\t{t|broadcast} {t|multicast}') \
+ + fmt.nl('\t{t|peer} {t|anycast}')
+
+ if self.valid_lifetime:
+ buf += fmt.nl('\t{s|valid-lifetime!k} '\
+ '{a|valid_lifetime}')
+
+ if self.preferred_lifetime:
+ buf += fmt.nl('\t{s|preferred-lifetime!k} '\
+ '{a|preferred_lifetime}')
+
+ if stats and (self.create_time or self.last_update):
+ buf += self.nl('\t{s|created!k} {a|create_time}'\
+ ' {s|last-updated!k} {a|last_update}')
+
+ return buf
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/capi.i b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/capi.i
new file mode 100644
index 0000000..2d72bd7
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/capi.i
@@ -0,0 +1,507 @@
+%module capi
+%{
+#include <netlink/route/rtnl.h>
+#include <netlink/route/link.h>
+#include <netlink/route/link/vlan.h>
+#include <netlink/route/link/macvlan.h>
+#include <netlink/route/link/vxlan.h>
+#include <netlink/route/link/bridge.h>
+#include <netlink/route/link/inet.h>
+
+#include <netlink/route/tc.h>
+#include <netlink/route/qdisc.h>
+#include <netlink/route/class.h>
+#include <netlink/route/classifier.h>
+
+#include <netlink/route/qdisc/htb.h>
+
+#include <netlink/route/addr.h>
+%}
+
+%include <stdint.i>
+%include <cstring.i>
+
+%inline %{
+ struct nl_object *link2obj(struct rtnl_link *link)
+ {
+ return OBJ_CAST(link);
+ }
+
+ struct rtnl_link *obj2link(struct nl_object *obj)
+ {
+ return (struct rtnl_link *) obj;
+ }
+
+ struct rtnl_link *get_from_kernel(struct nl_sock *sk, int ifindex, const char *name)
+ {
+ struct rtnl_link *link;
+ if (rtnl_link_get_kernel(sk, ifindex, name, &link) < 0)
+ return NULL;
+ return link;
+ }
+
+ uint32_t inet_get_conf(struct rtnl_link *link, const unsigned int id)
+ {
+ uint32_t result;
+
+ if (rtnl_link_inet_get_conf(link, id, &result) < 0)
+ return 0;
+
+ return result;
+ }
+%};
+
+extern struct nl_object *link2obj(struct rtnl_link *);
+extern struct rtnl_link *obj2link(struct nl_object *);
+
+/* <netlink/route/rtnl.h> */
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char * rtnl_scope2str(int, char *buf, size_t len);
+extern int rtnl_str2scope(const char *);
+
+/* <netlink/route/link.h> */
+
+extern struct rtnl_link *rtnl_link_alloc(void);
+
+extern struct rtnl_link *rtnl_link_get(struct nl_cache *, int);
+extern struct rtnl_link *rtnl_link_get_by_name(struct nl_cache *, const char *);
+
+extern int rtnl_link_build_add_request(struct rtnl_link *, int, struct nl_msg **);
+extern int rtnl_link_add(struct nl_sock *, struct rtnl_link *, int);
+extern int rtnl_link_build_change_request(struct rtnl_link *, struct rtnl_link *, int, struct nl_msg **);
+extern int rtnl_link_change(struct nl_sock *, struct rtnl_link *, struct rtnl_link *, int);
+
+extern int rtnl_link_build_delete_request(const struct rtnl_link *, struct nl_msg **);
+extern int rtnl_link_delete(struct nl_sock *, const struct rtnl_link *);
+extern int rtnl_link_build_get_request(int, const char *, struct nl_msg **);
+
+extern char *rtnl_link_stat2str(int, char *, size_t);
+extern int rtnl_link_str2stat(const char *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *rtnl_link_flags2str(int, char *buf, size_t len);
+extern int rtnl_link_str2flags(const char *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *rtnl_link_operstate2str(uint8_t, char *buf, size_t len);
+extern int rtnl_link_str2operstate(const char *);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *rtnl_link_mode2str(uint8_t, char *buf, size_t len);
+extern int rtnl_link_str2mode(const char *);
+
+extern void rtnl_link_set_qdisc(struct rtnl_link *, const char *);
+extern char *rtnl_link_get_qdisc(struct rtnl_link *);
+
+extern void rtnl_link_set_name(struct rtnl_link *, const char *);
+extern char *rtnl_link_get_name(struct rtnl_link *);
+
+extern void rtnl_link_set_flags(struct rtnl_link *, unsigned int);
+extern void rtnl_link_unset_flags(struct rtnl_link *, unsigned int);
+extern unsigned int rtnl_link_get_flags(struct rtnl_link *);
+
+extern void rtnl_link_set_mtu(struct rtnl_link *, unsigned int);
+extern unsigned int rtnl_link_get_mtu(struct rtnl_link *);
+
+extern void rtnl_link_set_txqlen(struct rtnl_link *, unsigned int);
+extern unsigned int rtnl_link_get_txqlen(struct rtnl_link *);
+
+extern void rtnl_link_set_ifindex(struct rtnl_link *, int);
+extern int rtnl_link_get_ifindex(struct rtnl_link *);
+
+extern void rtnl_link_set_family(struct rtnl_link *, int);
+extern int rtnl_link_get_family(struct rtnl_link *);
+
+extern void rtnl_link_set_arptype(struct rtnl_link *, unsigned int);
+extern unsigned int rtnl_link_get_arptype(struct rtnl_link *);
+
+extern void rtnl_link_set_addr(struct rtnl_link *, struct nl_addr *);
+extern struct nl_addr *rtnl_link_get_addr(struct rtnl_link *);
+
+extern void rtnl_link_set_broadcast(struct rtnl_link *, struct nl_addr *);
+extern struct nl_addr *rtnl_link_get_broadcast(struct rtnl_link *);
+
+extern void rtnl_link_set_link(struct rtnl_link *, int);
+extern int rtnl_link_get_link(struct rtnl_link *);
+
+extern void rtnl_link_set_master(struct rtnl_link *, int);
+extern int rtnl_link_get_master(struct rtnl_link *);
+
+extern void rtnl_link_set_operstate(struct rtnl_link *, uint8_t);
+extern uint8_t rtnl_link_get_operstate(struct rtnl_link *);
+
+extern void rtnl_link_set_linkmode(struct rtnl_link *, uint8_t);
+extern uint8_t rtnl_link_get_linkmode(struct rtnl_link *);
+
+extern const char *rtnl_link_get_ifalias(struct rtnl_link *);
+extern void rtnl_link_set_ifalias(struct rtnl_link *, const char *);
+
+extern int rtnl_link_get_num_vf(struct rtnl_link *, uint32_t *);
+
+extern uint64_t rtnl_link_get_stat(struct rtnl_link *, int);
+extern int rtnl_link_set_stat(struct rtnl_link *, const unsigned int, const uint64_t);
+
+extern int rtnl_link_set_type(struct rtnl_link *, const char *);
+extern char *rtnl_link_get_type(struct rtnl_link *);
+
+extern int rtnl_link_enslave(struct nl_sock * sock, struct rtnl_link * master, struct rtnl_link * slave);
+extern int rtnl_link_release(struct nl_sock * sock, struct rtnl_link * slave);
+
+/* <netlink/route/link/vlan.h> */
+
+struct vlan_map
+{
+ uint32_t vm_from;
+ uint32_t vm_to;
+};
+
+#define VLAN_PRIO_MAX 7
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char *rtnl_link_vlan_flags2str(int, char *buf, size_t len);
+extern int rtnl_link_vlan_str2flags(const char *);
+
+extern int rtnl_link_vlan_set_id(struct rtnl_link *, int);
+extern int rtnl_link_vlan_get_id(struct rtnl_link *);
+
+extern int rtnl_link_vlan_set_flags(struct rtnl_link *, unsigned int);
+extern int rtnl_link_vlan_unset_flags(struct rtnl_link *, unsigned int);
+extern unsigned int rtnl_link_vlan_get_flags(struct rtnl_link *);
+
+extern int rtnl_link_vlan_set_ingress_map(struct rtnl_link *, int, uint32_t);
+extern uint32_t *rtnl_link_vlan_get_ingress_map(struct rtnl_link *);
+
+extern int rtnl_link_vlan_set_egress_map(struct rtnl_link *, uint32_t, int);
+extern struct vlan_map *rtnl_link_vlan_get_egress_map(struct rtnl_link *, int *);
+
+/* <netlink/route/link/macvlan.h> */
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern struct rtnl_link *rtnl_link_macvlan_alloc(void);
+extern int rtnl_link_is_macvlan(struct rtnl_link *);
+extern char * rtnl_link_macvlan_mode2str(int, char *, size_t);
+extern int rtnl_link_macvlan_str2mode(const char *);
+extern char * rtnl_link_macvlan_flags2str(int, char *, size_t);
+extern int rtnl_link_macvlan_str2flags(const char *);
+extern int rtnl_link_macvlan_set_mode(struct rtnl_link *, uint32_t);
+extern uint32_t rtnl_link_macvlan_get_mode(struct rtnl_link *);
+extern int rtnl_link_macvlan_set_flags(struct rtnl_link *, uint16_t);
+extern int rtnl_link_macvlan_unset_flags(struct rtnl_link *, uint16_t);
+extern uint16_t rtnl_link_macvlan_get_flags(struct rtnl_link *);
+
+/* <netlink/route/link/vxlan.h> */
+
+#define VXLAN_ID_MAX 16777215
+
+extern struct rtnl_link *rtnl_link_vxlan_alloc(void);
+
+extern int rtnl_link_is_vxlan(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_id(struct rtnl_link *, uint32_t);
+extern int rtnl_link_vxlan_get_id(struct rtnl_link *, uint32_t *);
+
+extern int rtnl_link_vxlan_set_group(struct rtnl_link *, struct nl_addr *);
+extern int rtnl_link_vxlan_get_group(struct rtnl_link *, struct nl_addr **);
+
+extern int rtnl_link_vxlan_set_link(struct rtnl_link *, uint32_t);
+extern int rtnl_link_vxlan_get_link(struct rtnl_link *, uint32_t *);
+
+extern int rtnl_link_vxlan_set_local(struct rtnl_link *, struct nl_addr *);
+extern int rtnl_link_vxlan_get_local(struct rtnl_link *, struct nl_addr **);
+
+extern int rtnl_link_vxlan_set_ttl(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_ttl(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_tos(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_tos(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_learning(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_learning(struct rtnl_link *);
+extern int rtnl_link_vxlan_enable_learning(struct rtnl_link *);
+extern int rtnl_link_vxlan_disable_learning(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_ageing(struct rtnl_link *, uint32_t);
+extern int rtnl_link_vxlan_get_ageing(struct rtnl_link *, uint32_t *);
+
+extern int rtnl_link_vxlan_set_limit(struct rtnl_link *, uint32_t);
+extern int rtnl_link_vxlan_get_limit(struct rtnl_link *, uint32_t *);
+
+extern int rtnl_link_vxlan_set_port_range(struct rtnl_link *,
+ struct ifla_vxlan_port_range *);
+extern int rtnl_link_vxlan_get_port_range(struct rtnl_link *,
+ struct ifla_vxlan_port_range *);
+
+extern int rtnl_link_vxlan_set_proxy(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_proxy(struct rtnl_link *);
+extern int rtnl_link_vxlan_enable_proxy(struct rtnl_link *);
+extern int rtnl_link_vxlan_disable_proxy(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_rsc(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_rsc(struct rtnl_link *);
+extern int rtnl_link_vxlan_enable_rsc(struct rtnl_link *);
+extern int rtnl_link_vxlan_disable_rsc(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_l2miss(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_l2miss(struct rtnl_link *);
+extern int rtnl_link_vxlan_enable_l2miss(struct rtnl_link *);
+extern int rtnl_link_vxlan_disable_l2miss(struct rtnl_link *);
+
+extern int rtnl_link_vxlan_set_l3miss(struct rtnl_link *, uint8_t);
+extern int rtnl_link_vxlan_get_l3miss(struct rtnl_link *);
+extern int rtnl_link_vxlan_enable_l3miss(struct rtnl_link *);
+extern int rtnl_link_vxlan_disable_l3miss(struct rtnl_link *);
+
+/* <netlink/route/link/bridge.h> */
+
+enum rtnl_link_bridge_flags {
+ RTNL_BRIDGE_HAIRPIN_MODE = 0x0001,
+ RTNL_BRIDGE_BPDU_GUARD = 0x0002,
+ RTNL_BRIDGE_ROOT_BLOCK = 0x0004,
+ RTNL_BRIDGE_FAST_LEAVE = 0x0008,
+};
+
+extern int rtnl_link_is_bridge(struct rtnl_link *);
+extern int rtnl_link_bridge_has_ext_info(struct rtnl_link *);
+
+extern int rtnl_link_bridge_set_port_state(struct rtnl_link *, uint8_t );
+extern int rtnl_link_bridge_get_port_state(struct rtnl_link *);
+
+extern int rtnl_link_bridge_set_priority(struct rtnl_link *, uint16_t);
+extern int rtnl_link_bridge_get_priority(struct rtnl_link *);
+
+extern int rtnl_link_bridge_set_cost(struct rtnl_link *, uint32_t);
+extern int rtnl_link_bridge_get_cost(struct rtnl_link *, uint32_t *);
+
+extern int rtnl_link_bridge_unset_flags(struct rtnl_link *, unsigned int);
+extern int rtnl_link_bridge_set_flags(struct rtnl_link *, unsigned int);
+extern int rtnl_link_bridge_get_flags(struct rtnl_link *);
+
+extern char * rtnl_link_bridge_flags2str(int, char *, size_t);
+extern int rtnl_link_bridge_str2flags(const char *);
+
+/* <netlink/route/link/inet.h> */
+%cstring_output_maxsize(char *buf, size_t len)
+extern const char *rtnl_link_inet_devconf2str(int, char *buf, size_t len);
+extern unsigned int rtnl_link_inet_str2devconf(const char *);
+
+extern int rtnl_link_inet_set_conf(struct rtnl_link *, const unsigned int, uint32_t);
+
+/* <netlink/route/tc.h> */
+
+%inline %{
+ uint32_t tc_str2handle(const char *name)
+ {
+ uint32_t result;
+
+ if (rtnl_tc_str2handle(name, &result) < 0)
+ return 0;
+
+ return result;
+ }
+%};
+
+extern void rtnl_tc_set_ifindex(struct rtnl_tc *, int);
+extern int rtnl_tc_get_ifindex(struct rtnl_tc *);
+extern void rtnl_tc_set_link(struct rtnl_tc *, struct rtnl_link *);
+extern struct rtnl_link *rtnl_tc_get_link(struct rtnl_tc *);
+extern void rtnl_tc_set_mtu(struct rtnl_tc *, uint32_t);
+extern uint32_t rtnl_tc_get_mtu(struct rtnl_tc *);
+extern void rtnl_tc_set_mpu(struct rtnl_tc *, uint32_t);
+extern uint32_t rtnl_tc_get_mpu(struct rtnl_tc *);
+extern void rtnl_tc_set_overhead(struct rtnl_tc *, uint32_t);
+extern uint32_t rtnl_tc_get_overhead(struct rtnl_tc *);
+extern void rtnl_tc_set_linktype(struct rtnl_tc *, uint32_t);
+extern uint32_t rtnl_tc_get_linktype(struct rtnl_tc *);
+extern void rtnl_tc_set_handle(struct rtnl_tc *, uint32_t);
+extern uint32_t rtnl_tc_get_handle(struct rtnl_tc *);
+extern void rtnl_tc_set_parent(struct rtnl_tc *, uint32_t);
+extern uint32_t rtnl_tc_get_parent(struct rtnl_tc *);
+extern int rtnl_tc_set_kind(struct rtnl_tc *, const char *);
+extern char * rtnl_tc_get_kind(struct rtnl_tc *);
+extern uint64_t rtnl_tc_get_stat(struct rtnl_tc *, enum rtnl_tc_stat);
+
+extern int rtnl_tc_calc_txtime(int, int);
+extern int rtnl_tc_calc_bufsize(int, int);
+extern int rtnl_tc_calc_cell_log(int);
+
+extern int rtnl_tc_read_classid_file(void);
+%cstring_output_maxsize(char *buf, size_t len)
+extern char * rtnl_tc_handle2str(uint32_t, char *buf, size_t len);
+extern int rtnl_classid_generate(const char *, uint32_t *, uint32_t);
+
+/* <netlink/route/qdisc.h> */
+
+%inline %{
+ struct nl_object *qdisc2obj(struct rtnl_qdisc *qdisc)
+ {
+ return OBJ_CAST(qdisc);
+ }
+
+ struct rtnl_qdisc *obj2qdisc(struct nl_object *obj)
+ {
+ return (struct rtnl_qdisc *) obj;
+ }
+
+ struct nl_object *class2obj(struct rtnl_class *cl)
+ {
+ return OBJ_CAST(cl);
+ }
+
+ struct rtnl_class *obj2class(struct nl_object *obj)
+ {
+ return (struct rtnl_class *) obj;
+ }
+
+ struct nl_object *cls2obj(struct rtnl_cls *cls)
+ {
+ return OBJ_CAST(cls);
+ }
+
+ struct rtnl_cls *obj2cls(struct nl_object *obj)
+ {
+ return (struct rtnl_cls *) obj;
+ }
+
+ struct rtnl_tc *obj2tc(struct nl_object *obj)
+ {
+ return TC_CAST(obj);
+ }
+%};
+extern struct rtnl_qdisc *
+ rtnl_qdisc_alloc(void);
+
+extern struct rtnl_qdisc *
+ rtnl_qdisc_get(struct nl_cache *, int, uint32_t);
+
+extern struct rtnl_qdisc *
+ rtnl_qdisc_get_by_parent(struct nl_cache *, int, uint32_t);
+
+extern int rtnl_qdisc_build_add_request(struct rtnl_qdisc *, int,
+ struct nl_msg **);
+extern int rtnl_qdisc_add(struct nl_sock *, struct rtnl_qdisc *, int);
+
+extern int rtnl_qdisc_build_update_request(struct rtnl_qdisc *,
+ struct rtnl_qdisc *,
+ int, struct nl_msg **);
+
+extern int rtnl_qdisc_update(struct nl_sock *, struct rtnl_qdisc *,
+ struct rtnl_qdisc *, int);
+
+extern int rtnl_qdisc_build_delete_request(struct rtnl_qdisc *,
+ struct nl_msg **);
+extern int rtnl_qdisc_delete(struct nl_sock *, struct rtnl_qdisc *);
+
+/* <netlink/route/classifier.h> */
+
+extern struct rtnl_cls *rtnl_cls_alloc(void);
+extern void rtnl_cls_put(struct rtnl_cls *);
+
+extern int rtnl_cls_add(struct nl_sock *, struct rtnl_cls *, int);
+
+extern int rtnl_cls_delete(struct nl_sock *, struct rtnl_cls *,
+ int);
+
+extern void rtnl_cls_set_prio(struct rtnl_cls *, uint16_t);
+extern uint16_t rtnl_cls_get_prio(struct rtnl_cls *);
+
+extern void rtnl_cls_set_protocol(struct rtnl_cls *, uint16_t);
+extern uint16_t rtnl_cls_get_protocol(struct rtnl_cls *);
+
+/* <netlink/route/qdisc/htb.h> */
+
+extern uint32_t rtnl_htb_get_rate2quantum(struct rtnl_qdisc *);
+extern int rtnl_htb_set_rate2quantum(struct rtnl_qdisc *, uint32_t);
+extern uint32_t rtnl_htb_get_defcls(struct rtnl_qdisc *);
+extern int rtnl_htb_set_defcls(struct rtnl_qdisc *, uint32_t);
+
+extern uint32_t rtnl_htb_get_prio(struct rtnl_class *);
+extern int rtnl_htb_set_prio(struct rtnl_class *, uint32_t);
+extern uint32_t rtnl_htb_get_rate(struct rtnl_class *);
+extern int rtnl_htb_set_rate(struct rtnl_class *, uint32_t);
+extern uint32_t rtnl_htb_get_ceil(struct rtnl_class *);
+extern int rtnl_htb_set_ceil(struct rtnl_class *, uint32_t);
+extern uint32_t rtnl_htb_get_rbuffer(struct rtnl_class *);
+extern int rtnl_htb_set_rbuffer(struct rtnl_class *, uint32_t);
+extern uint32_t rtnl_htb_get_cbuffer(struct rtnl_class *);
+extern int rtnl_htb_set_cbuffer(struct rtnl_class *, uint32_t);
+extern uint32_t rtnl_htb_get_quantum(struct rtnl_class *);
+extern int rtnl_htb_set_quantum(struct rtnl_class *, uint32_t);
+extern int rtnl_htb_get_level(struct rtnl_class *);
+
+/* <netlink/route/addr.h> */
+
+%inline %{
+ struct nl_object *addr2obj(struct rtnl_addr *addr)
+ {
+ return OBJ_CAST(addr);
+ }
+
+ struct rtnl_addr *obj2addr(struct nl_object *obj)
+ {
+ return (struct rtnl_addr *) obj;
+ }
+%};
+
+extern struct rtnl_addr *rtnl_addr_alloc(void);
+
+extern struct rtnl_addr *
+ rtnl_addr_get(struct nl_cache *, int, struct nl_addr *);
+
+extern int rtnl_addr_build_add_request(struct rtnl_addr *, int,
+ struct nl_msg **);
+extern int rtnl_addr_add(struct nl_sock *, struct rtnl_addr *, int);
+
+extern int rtnl_addr_build_delete_request(struct rtnl_addr *, int,
+ struct nl_msg **);
+extern int rtnl_addr_delete(struct nl_sock *,
+ struct rtnl_addr *, int);
+
+%cstring_output_maxsize(char *buf, size_t len)
+extern char * rtnl_addr_flags2str(int, char *buf, size_t len);
+extern int rtnl_addr_str2flags(const char *);
+
+extern int rtnl_addr_set_label(struct rtnl_addr *, const char *);
+extern char * rtnl_addr_get_label(struct rtnl_addr *);
+
+extern void rtnl_addr_set_ifindex(struct rtnl_addr *, int);
+extern int rtnl_addr_get_ifindex(struct rtnl_addr *);
+
+extern void rtnl_addr_set_link(struct rtnl_addr *, struct rtnl_link *);
+extern struct rtnl_link *
+ rtnl_addr_get_link(struct rtnl_addr *);
+extern void rtnl_addr_set_family(struct rtnl_addr *, int);
+extern int rtnl_addr_get_family(struct rtnl_addr *);
+
+extern void rtnl_addr_set_prefixlen(struct rtnl_addr *, int);
+extern int rtnl_addr_get_prefixlen(struct rtnl_addr *);
+
+extern void rtnl_addr_set_scope(struct rtnl_addr *, int);
+extern int rtnl_addr_get_scope(struct rtnl_addr *);
+
+extern void rtnl_addr_set_flags(struct rtnl_addr *, unsigned int);
+extern void rtnl_addr_unset_flags(struct rtnl_addr *, unsigned int);
+extern unsigned int rtnl_addr_get_flags(struct rtnl_addr *);
+
+extern int rtnl_addr_set_local(struct rtnl_addr *,
+ struct nl_addr *);
+extern struct nl_addr *rtnl_addr_get_local(struct rtnl_addr *);
+
+extern int rtnl_addr_set_peer(struct rtnl_addr *, struct nl_addr *);
+extern struct nl_addr *rtnl_addr_get_peer(struct rtnl_addr *);
+
+extern int rtnl_addr_set_broadcast(struct rtnl_addr *, struct nl_addr *);
+extern struct nl_addr *rtnl_addr_get_broadcast(struct rtnl_addr *);
+
+extern int rtnl_addr_set_multicast(struct rtnl_addr *, struct nl_addr *);
+extern struct nl_addr *rtnl_addr_get_multicast(struct rtnl_addr *);
+
+extern int rtnl_addr_set_anycast(struct rtnl_addr *, struct nl_addr *);
+extern struct nl_addr *rtnl_addr_get_anycast(struct rtnl_addr *);
+
+extern uint32_t rtnl_addr_get_valid_lifetime(struct rtnl_addr *);
+extern void rtnl_addr_set_valid_lifetime(struct rtnl_addr *, uint32_t);
+extern uint32_t rtnl_addr_get_preferred_lifetime(struct rtnl_addr *);
+extern void rtnl_addr_set_preferred_lifetime(struct rtnl_addr *, uint32_t);
+extern uint32_t rtnl_addr_get_create_time(struct rtnl_addr *);
+extern uint32_t rtnl_addr_get_last_update_time(struct rtnl_addr *);
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/link.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/link.py
new file mode 100644
index 0000000..5ec14b2
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/link.py
@@ -0,0 +1,551 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""Module providing access to network links
+
+This module provides an interface to view configured network links,
+modify them and to add and delete virtual network links.
+
+The following is a basic example:
+ import netlink.core as netlink
+ import netlink.route.link as link
+
+ sock = netlink.Socket()
+ sock.connect(netlink.NETLINK_ROUTE)
+
+ cache = link.LinkCache() # create new empty link cache
+ cache.refill(sock) # fill cache with all configured links
+ eth0 = cache['eth0'] # lookup link "eth0"
+ print eth0 # print basic configuration
+
+The module contains the following public classes:
+
+ - Link -- Represents a network link. Instances can be created directly
+ via the constructor (empty link objects) or via the refill()
+ method of a LinkCache.
+ - LinkCache -- Derived from netlink.Cache, holds any number of
+ network links (Link instances). Main purpose is to keep
+ a local list of all network links configured in the
+ kernel.
+
+The following public functions exist:
+ - get_from_kernel(socket, name)
+
+"""
+
+from __future__ import absolute_import
+
+__version__ = '0.1'
+__all__ = [
+ 'LinkCache',
+ 'Link',
+ 'get_from_kernel',
+]
+
+import socket
+from .. import core as netlink
+from .. import capi as core_capi
+from . import capi as capi
+from .links import inet as inet
+from .. import util as util
+
+# Link statistics definitions
+RX_PACKETS = 0
+TX_PACKETS = 1
+RX_BYTES = 2
+TX_BYTES = 3
+RX_ERRORS = 4
+TX_ERRORS = 5
+RX_DROPPED = 6
+TX_DROPPED = 7
+RX_COMPRESSED = 8
+TX_COMPRESSED = 9
+RX_FIFO_ERR = 10
+TX_FIFO_ERR = 11
+RX_LEN_ERR = 12
+RX_OVER_ERR = 13
+RX_CRC_ERR = 14
+RX_FRAME_ERR = 15
+RX_MISSED_ERR = 16
+TX_ABORT_ERR = 17
+TX_CARRIER_ERR = 18
+TX_HBEAT_ERR = 19
+TX_WIN_ERR = 20
+COLLISIONS = 21
+MULTICAST = 22
+IP6_INPKTS = 23
+IP6_INHDRERRORS = 24
+IP6_INTOOBIGERRORS = 25
+IP6_INNOROUTES = 26
+IP6_INADDRERRORS = 27
+IP6_INUNKNOWNPROTOS = 28
+IP6_INTRUNCATEDPKTS = 29
+IP6_INDISCARDS = 30
+IP6_INDELIVERS = 31
+IP6_OUTFORWDATAGRAMS = 32
+IP6_OUTPKTS = 33
+IP6_OUTDISCARDS = 34
+IP6_OUTNOROUTES = 35
+IP6_REASMTIMEOUT = 36
+IP6_REASMREQDS = 37
+IP6_REASMOKS = 38
+IP6_REASMFAILS = 39
+IP6_FRAGOKS = 40
+IP6_FRAGFAILS = 41
+IP6_FRAGCREATES = 42
+IP6_INMCASTPKTS = 43
+IP6_OUTMCASTPKTS = 44
+IP6_INBCASTPKTS = 45
+IP6_OUTBCASTPKTS = 46
+IP6_INOCTETS = 47
+IP6_OUTOCTETS = 48
+IP6_INMCASTOCTETS = 49
+IP6_OUTMCASTOCTETS = 50
+IP6_INBCASTOCTETS = 51
+IP6_OUTBCASTOCTETS = 52
+ICMP6_INMSGS = 53
+ICMP6_INERRORS = 54
+ICMP6_OUTMSGS = 55
+ICMP6_OUTERRORS = 56
+
+class LinkCache(netlink.Cache):
+ """Cache of network links"""
+
+ def __init__(self, family=socket.AF_UNSPEC, cache=None):
+ if not cache:
+ cache = self._alloc_cache_name('route/link')
+
+ self._info_module = None
+ self._protocol = netlink.NETLINK_ROUTE
+ self._nl_cache = cache
+ self._set_arg1(family)
+
+ def __getitem__(self, key):
+ if type(key) is int:
+ link = capi.rtnl_link_get(self._nl_cache, key)
+ else:
+ link = capi.rtnl_link_get_by_name(self._nl_cache, key)
+
+ if link is None:
+ raise KeyError()
+ else:
+ return Link.from_capi(link)
+
+ @staticmethod
+ def _new_object(obj):
+ return Link(obj)
+
+ def _new_cache(self, cache):
+ return LinkCache(family=self.arg1, cache=cache)
+
+class Link(netlink.Object):
+ """Network link"""
+
+ def __init__(self, obj=None):
+ netlink.Object.__init__(self, 'route/link', 'link', obj)
+ self._rtnl_link = self._obj2type(self._nl_object)
+
+ if self.type:
+ self._module_lookup('netlink.route.links.' + self.type)
+
+ self.inet = inet.InetLink(self)
+ self.af = {'inet' : self.inet }
+
+ def __enter__(self):
+ return self
+
+ def __exit__(self, exc_type, exc_value, tb):
+ if exc_type is None:
+ self.change()
+ else:
+ return false
+
+ @classmethod
+ def from_capi(cls, obj):
+ return cls(capi.link2obj(obj))
+
+ @staticmethod
+ def _obj2type(obj):
+ return capi.obj2link(obj)
+
+ def __cmp__(self, other):
+ return self.ifindex - other.ifindex
+
+ @staticmethod
+ def _new_instance(obj):
+ if not obj:
+ raise ValueError()
+
+ return Link(obj)
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def ifindex(self):
+ """interface index"""
+ return capi.rtnl_link_get_ifindex(self._rtnl_link)
+
+ @ifindex.setter
+ def ifindex(self, value):
+ capi.rtnl_link_set_ifindex(self._rtnl_link, int(value))
+
+ # ifindex is immutable but we assume that if _orig does not
+ # have an ifindex specified, it was meant to be given here
+ if capi.rtnl_link_get_ifindex(self._orig) == 0:
+ capi.rtnl_link_set_ifindex(self._orig, int(value))
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.bold)
+ def name(self):
+ """Name of link"""
+ return capi.rtnl_link_get_name(self._rtnl_link)
+
+ @name.setter
+ def name(self, value):
+ capi.rtnl_link_set_name(self._rtnl_link, value)
+
+ # name is the secondary identifier, if _orig does not have
+ # the name specified yet, assume it was meant to be specified
+ # here. ifindex will always take priority, therefore if ifindex
+ # is specified as well, this will be ignored automatically.
+ if capi.rtnl_link_get_name(self._orig) is None:
+ capi.rtnl_link_set_name(self._orig, value)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.string)
+ def flags(self):
+ """Flags
+ Setting this property will *Not* reset flags to value you supply in
+ Examples:
+ link.flags = '+xxx' # add xxx flag
+ link.flags = 'xxx' # exactly the same
+ link.flags = '-xxx' # remove xxx flag
+ link.flags = [ '+xxx', '-yyy' ] # list operation
+ """
+ flags = capi.rtnl_link_get_flags(self._rtnl_link)
+ return capi.rtnl_link_flags2str(flags, 256)[0].split(',')
+
+ def _set_flag(self, flag):
+ if flag.startswith('-'):
+ i = capi.rtnl_link_str2flags(flag[1:])
+ capi.rtnl_link_unset_flags(self._rtnl_link, i)
+ elif flag.startswith('+'):
+ i = capi.rtnl_link_str2flags(flag[1:])
+ capi.rtnl_link_set_flags(self._rtnl_link, i)
+ else:
+ i = capi.rtnl_link_str2flags(flag)
+ capi.rtnl_link_set_flags(self._rtnl_link, i)
+
+ @flags.setter
+ def flags(self, value):
+ if not (type(value) is str):
+ for flag in value:
+ self._set_flag(flag)
+ else:
+ self._set_flag(value)
+
+ @property
+ @netlink.nlattr(type=int, fmt=util.num)
+ def mtu(self):
+ """Maximum Transmission Unit"""
+ return capi.rtnl_link_get_mtu(self._rtnl_link)
+
+ @mtu.setter
+ def mtu(self, value):
+ capi.rtnl_link_set_mtu(self._rtnl_link, int(value))
+
+ @property
+ @netlink.nlattr(type=int, immutable=True, fmt=util.num)
+ def family(self):
+ """Address family"""
+ return capi.rtnl_link_get_family(self._rtnl_link)
+
+ @family.setter
+ def family(self, value):
+ capi.rtnl_link_set_family(self._rtnl_link, value)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.addr)
+ def address(self):
+ """Hardware address (MAC address)"""
+ a = capi.rtnl_link_get_addr(self._rtnl_link)
+ return netlink.AbstractAddress(a)
+
+ @address.setter
+ def address(self, value):
+ capi.rtnl_link_set_addr(self._rtnl_link, value._addr)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.addr)
+ def broadcast(self):
+ """Hardware broadcast address"""
+ a = capi.rtnl_link_get_broadcast(self._rtnl_link)
+ return netlink.AbstractAddress(a)
+
+ @broadcast.setter
+ def broadcast(self, value):
+ capi.rtnl_link_set_broadcast(self._rtnl_link, value._addr)
+
+ @property
+ @netlink.nlattr(type=str, immutable=True, fmt=util.string)
+ def qdisc(self):
+ """Name of qdisc (cannot be changed)"""
+ return capi.rtnl_link_get_qdisc(self._rtnl_link)
+
+ @qdisc.setter
+ def qdisc(self, value):
+ capi.rtnl_link_set_qdisc(self._rtnl_link, value)
+
+ @property
+ @netlink.nlattr(type=int, fmt=util.num)
+ def txqlen(self):
+ """Length of transmit queue"""
+ return capi.rtnl_link_get_txqlen(self._rtnl_link)
+
+ @txqlen.setter
+ def txqlen(self, value):
+ capi.rtnl_link_set_txqlen(self._rtnl_link, int(value))
+
+ @property
+ @netlink.nlattr(type=str, immutable=True, fmt=util.string)
+ def arptype(self):
+ """Type of link (cannot be changed)"""
+ type_ = capi.rtnl_link_get_arptype(self._rtnl_link)
+ return core_capi.nl_llproto2str(type_, 64)[0]
+
+ @arptype.setter
+ def arptype(self, value):
+ i = core_capi.nl_str2llproto(value)
+ capi.rtnl_link_set_arptype(self._rtnl_link, i)
+
+ @property
+ @netlink.nlattr(type=str, immutable=True, fmt=util.string, title='state')
+ def operstate(self):
+ """Operational status"""
+ operstate = capi.rtnl_link_get_operstate(self._rtnl_link)
+ return capi.rtnl_link_operstate2str(operstate, 32)[0]
+
+ @operstate.setter
+ def operstate(self, value):
+ i = capi.rtnl_link_str2operstate(value)
+ capi.rtnl_link_set_operstate(self._rtnl_link, i)
+
+ @property
+ @netlink.nlattr(type=str, immutable=True, fmt=util.string)
+ def mode(self):
+ """Link mode"""
+ mode = capi.rtnl_link_get_linkmode(self._rtnl_link)
+ return capi.rtnl_link_mode2str(mode, 32)[0]
+
+ @mode.setter
+ def mode(self, value):
+ i = capi.rtnl_link_str2mode(value)
+ capi.rtnl_link_set_linkmode(self._rtnl_link, i)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.string)
+ def alias(self):
+ """Interface alias (SNMP)"""
+ return capi.rtnl_link_get_ifalias(self._rtnl_link)
+
+ @alias.setter
+ def alias(self, value):
+ capi.rtnl_link_set_ifalias(self._rtnl_link, value)
+
+ @property
+ @netlink.nlattr(type=str, fmt=util.string)
+ def type(self):
+ """Link type"""
+ return capi.rtnl_link_get_type(self._rtnl_link)
+
+ @type.setter
+ def type(self, value):
+ if capi.rtnl_link_set_type(self._rtnl_link, value) < 0:
+ raise NameError('unknown info type')
+
+ self._module_lookup('netlink.route.links.' + value)
+
+ def get_stat(self, stat):
+ """Retrieve statistical information"""
+ if type(stat) is str:
+ stat = capi.rtnl_link_str2stat(stat)
+ if stat < 0:
+ raise NameError('unknown name of statistic')
+
+ return capi.rtnl_link_get_stat(self._rtnl_link, stat)
+
+ def enslave(self, slave, sock=None):
+ if not sock:
+ sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ return capi.rtnl_link_enslave(sock._sock, self._rtnl_link, slave._rtnl_link)
+
+ def release(self, slave, sock=None):
+ if not sock:
+ sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ return capi.rtnl_link_release(sock._sock, self._rtnl_link, slave._rtnl_link)
+
+ def add(self, sock=None, flags=None):
+ if not sock:
+ sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ if not flags:
+ flags = netlink.NLM_F_CREATE
+
+ ret = capi.rtnl_link_add(sock._sock, self._rtnl_link, flags)
+ if ret < 0:
+ raise netlink.KernelError(ret)
+
+ def change(self, sock=None, flags=0):
+ """Commit changes made to the link object"""
+ if sock is None:
+ sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ if not self._orig:
+ raise netlink.NetlinkError('Original link not available')
+ ret = capi.rtnl_link_change(sock._sock, self._orig, self._rtnl_link, flags)
+ if ret < 0:
+ raise netlink.KernelError(ret)
+
+ def delete(self, sock=None):
+ """Attempt to delete this link in the kernel"""
+ if sock is None:
+ sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ ret = capi.rtnl_link_delete(sock._sock, self._rtnl_link)
+ if ret < 0:
+ raise netlink.KernelError(ret)
+
+ ###################################################################
+ # private properties
+ #
+ # Used for formatting output. USE AT OWN RISK
+ @property
+ def _state(self):
+ if 'up' in self.flags:
+ buf = util.good('up')
+ if 'lowerup' not in self.flags:
+ buf += ' ' + util.bad('no-carrier')
+ else:
+ buf = util.bad('down')
+ return buf
+
+ @property
+ def _brief(self):
+ return self._module_brief() + self._foreach_af('brief')
+
+ @property
+ def _flags(self):
+ ignore = [
+ 'up',
+ 'running',
+ 'lowerup',
+ ]
+ return ','.join([flag for flag in self.flags if flag not in ignore])
+
+ def _foreach_af(self, name, args=None):
+ buf = ''
+ for af in self.af:
+ try:
+ func = getattr(self.af[af], name)
+ s = str(func(args))
+ if len(s) > 0:
+ buf += ' ' + s
+ except AttributeError:
+ pass
+ return buf
+
+ def format(self, details=False, stats=False, indent=''):
+ """Return link as formatted text"""
+ fmt = util.MyFormatter(self, indent)
+
+ buf = fmt.format('{a|ifindex} {a|name} {a|arptype} {a|address} '\
+ '{a|_state} <{a|_flags}> {a|_brief}')
+
+ if details:
+ buf += fmt.nl('\t{t|mtu} {t|txqlen} {t|weight} '\
+ '{t|qdisc} {t|operstate}')
+ buf += fmt.nl('\t{t|broadcast} {t|alias}')
+
+ buf += self._foreach_af('details', fmt)
+
+ if stats:
+ l = [['Packets', RX_PACKETS, TX_PACKETS],
+ ['Bytes', RX_BYTES, TX_BYTES],
+ ['Errors', RX_ERRORS, TX_ERRORS],
+ ['Dropped', RX_DROPPED, TX_DROPPED],
+ ['Compressed', RX_COMPRESSED, TX_COMPRESSED],
+ ['FIFO Errors', RX_FIFO_ERR, TX_FIFO_ERR],
+ ['Length Errors', RX_LEN_ERR, None],
+ ['Over Errors', RX_OVER_ERR, None],
+ ['CRC Errors', RX_CRC_ERR, None],
+ ['Frame Errors', RX_FRAME_ERR, None],
+ ['Missed Errors', RX_MISSED_ERR, None],
+ ['Abort Errors', None, TX_ABORT_ERR],
+ ['Carrier Errors', None, TX_CARRIER_ERR],
+ ['Heartbeat Errors', None, TX_HBEAT_ERR],
+ ['Window Errors', None, TX_WIN_ERR],
+ ['Collisions', None, COLLISIONS],
+ ['Multicast', None, MULTICAST],
+ ['', None, None],
+ ['Ipv6:', None, None],
+ ['Packets', IP6_INPKTS, IP6_OUTPKTS],
+ ['Bytes', IP6_INOCTETS, IP6_OUTOCTETS],
+ ['Discards', IP6_INDISCARDS, IP6_OUTDISCARDS],
+ ['Multicast Packets', IP6_INMCASTPKTS, IP6_OUTMCASTPKTS],
+ ['Multicast Bytes', IP6_INMCASTOCTETS, IP6_OUTMCASTOCTETS],
+ ['Broadcast Packets', IP6_INBCASTPKTS, IP6_OUTBCASTPKTS],
+ ['Broadcast Bytes', IP6_INBCASTOCTETS, IP6_OUTBCASTOCTETS],
+ ['Delivers', IP6_INDELIVERS, None],
+ ['Forwarded', None, IP6_OUTFORWDATAGRAMS],
+ ['No Routes', IP6_INNOROUTES, IP6_OUTNOROUTES],
+ ['Header Errors', IP6_INHDRERRORS, None],
+ ['Too Big Errors', IP6_INTOOBIGERRORS, None],
+ ['Address Errors', IP6_INADDRERRORS, None],
+ ['Unknown Protocol', IP6_INUNKNOWNPROTOS, None],
+ ['Truncated Packets', IP6_INTRUNCATEDPKTS, None],
+ ['Reasm Timeouts', IP6_REASMTIMEOUT, None],
+ ['Reasm Requests', IP6_REASMREQDS, None],
+ ['Reasm Failures', IP6_REASMFAILS, None],
+ ['Reasm OK', IP6_REASMOKS, None],
+ ['Frag Created', None, IP6_FRAGCREATES],
+ ['Frag Failures', None, IP6_FRAGFAILS],
+ ['Frag OK', None, IP6_FRAGOKS],
+ ['', None, None],
+ ['ICMPv6:', None, None],
+ ['Messages', ICMP6_INMSGS, ICMP6_OUTMSGS],
+ ['Errors', ICMP6_INERRORS, ICMP6_OUTERRORS]]
+
+ buf += '\n\t%s%s%s%s\n' % (33 * ' ', util.title('RX'),
+ 15 * ' ', util.title('TX'))
+
+ for row in l:
+ row[0] = util.kw(row[0])
+ row[1] = self.get_stat(row[1]) if row[1] else ''
+ row[2] = self.get_stat(row[2]) if row[2] else ''
+ buf += '\t{0[0]:27} {0[1]:>16} {0[2]:>16}\n'.format(row)
+
+ buf += self._foreach_af('stats')
+
+ return buf
+
+def get(name, sock=None):
+ """Lookup Link object directly from kernel"""
+ if not name:
+ raise ValueError()
+
+ if not sock:
+ sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+ link = capi.get_from_kernel(sock._sock, 0, name)
+ if not link:
+ return None
+
+ return Link.from_capi(link)
+
+_link_cache = LinkCache()
+
+def resolve(name):
+ _link_cache.refill()
+ return _link_cache[name]
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/__init__.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/__init__.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/dummy.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/dummy.py
new file mode 100644
index 0000000..e9491cc
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/dummy.py
@@ -0,0 +1,26 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""Dummy
+
+"""
+from __future__ import absolute_import
+
+__version__ = '1.0'
+__all__ = [
+ 'init',
+]
+
+
+class DummyLink(object):
+ def __init__(self, link):
+ self._rtnl_link = link
+
+ @staticmethod
+ def brief():
+ return 'dummy'
+
+def init(link):
+ link.dummy = DummyLink(link._rtnl_link)
+ return link.dummy
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/inet.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/inet.py
new file mode 100644
index 0000000..f5f45cb
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/inet.py
@@ -0,0 +1,158 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""IPv4
+
+"""
+
+from __future__ import absolute_import
+
+__all__ = [
+ '',
+]
+
+from ... import core as netlink
+from .. import capi as capi
+from ... import util as util
+DEVCONF_FORWARDING = 1
+DEVCONF_MC_FORWARDING = 2
+DEVCONF_PROXY_ARP = 3
+DEVCONF_ACCEPT_REDIRECTS = 4
+DEVCONF_SECURE_REDIRECTS = 5
+DEVCONF_SEND_REDIRECTS = 6
+DEVCONF_SHARED_MEDIA = 7
+DEVCONF_RP_FILTER = 8
+DEVCONF_ACCEPT_SOURCE_ROUTE = 9
+DEVCONF_BOOTP_RELAY = 10
+DEVCONF_LOG_MARTIANS = 11
+DEVCONF_TAG = 12
+DEVCONF_ARPFILTER = 13
+DEVCONF_MEDIUM_ID = 14
+DEVCONF_NOXFRM = 15
+DEVCONF_NOPOLICY = 16
+DEVCONF_FORCE_IGMP_VERSION = 17
+DEVCONF_ARP_ANNOUNCE = 18
+DEVCONF_ARP_IGNORE = 19
+DEVCONF_PROMOTE_SECONDARIES = 20
+DEVCONF_ARP_ACCEPT = 21
+DEVCONF_ARP_NOTIFY = 22
+DEVCONF_ACCEPT_LOCAL = 23
+DEVCONF_SRC_VMARK = 24
+DEVCONF_PROXY_ARP_PVLAN = 25
+DEVCONF_MAX = DEVCONF_PROXY_ARP_PVLAN
+
+def _resolve(id):
+ if type(id) is str:
+ id = capi.rtnl_link_inet_str2devconf(id)[0]
+ if id < 0:
+ raise NameError('unknown configuration id')
+ return id
+
+class InetLink(object):
+ def __init__(self, link):
+ self._link = link
+
+ def details(self, fmt):
+ buf = fmt.nl('\n\t{0}\n\t'.format(util.title('Configuration:')))
+
+ for i in range(DEVCONF_FORWARDING, DEVCONF_MAX+1):
+ if i & 1 and i > 1:
+ buf += fmt.nl('\t')
+ txt = util.kw(capi.rtnl_link_inet_devconf2str(i, 32)[0])
+ buf += fmt.format('{0:28s} {1:12} ', txt,
+ self.get_conf(i))
+
+
+ return buf
+
+ def get_conf(self, id):
+ return capi.inet_get_conf(self._link._rtnl_link, _resolve(id))
+
+ def set_conf(self, id, value):
+ return capi.rtnl_link_inet_set_conf(self._link._rtnl_link,
+ _resolve(id), int(value))
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def forwarding(self):
+ return bool(self.get_conf(DEVCONF_FORWARDING))
+
+ @forwarding.setter
+ def forwarding(self, value):
+ self.set_conf(DEVCONF_FORWARDING, int(value))
+
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def mc_forwarding(self):
+ return bool(self.get_conf(DEVCONF_MC_FORWARDING))
+
+ @mc_forwarding.setter
+ def mc_forwarding(self, value):
+ self.set_conf(DEVCONF_MC_FORWARDING, int(value))
+
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def proxy_arp(self):
+ return bool(self.get_conf(DEVCONF_PROXY_ARP))
+
+ @proxy_arp.setter
+ def proxy_arp(self, value):
+ self.set_conf(DEVCONF_PROXY_ARP, int(value))
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def accept_redirects(self):
+ return bool(self.get_conf(DEVCONF_ACCEPT_REDIRECTS))
+
+ @accept_redirects.setter
+ def accept_redirects(self, value):
+ self.set_conf(DEVCONF_ACCEPT_REDIRECTS, int(value))
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def secure_redirects(self):
+ return bool(self.get_conf(DEVCONF_SECURE_REDIRECTS))
+
+ @secure_redirects.setter
+ def secure_redirects(self, value):
+ self.set_conf(DEVCONF_SECURE_REDIRECTS, int(value))
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def send_redirects(self):
+ return bool(self.get_conf(DEVCONF_SEND_REDIRECTS))
+
+ @send_redirects.setter
+ def send_redirects(self, value):
+ self.set_conf(DEVCONF_SEND_REDIRECTS, int(value))
+
+ @property
+ @netlink.nlattr(type=bool, fmt=util.boolean)
+ def shared_media(self):
+ return bool(self.get_conf(DEVCONF_SHARED_MEDIA))
+
+ @shared_media.setter
+ def shared_media(self, value):
+ self.set_conf(DEVCONF_SHARED_MEDIA, int(value))
+
+# IPV4_DEVCONF_RP_FILTER,
+# IPV4_DEVCONF_ACCEPT_SOURCE_ROUTE,
+# IPV4_DEVCONF_BOOTP_RELAY,
+# IPV4_DEVCONF_LOG_MARTIANS,
+# IPV4_DEVCONF_TAG,
+# IPV4_DEVCONF_ARPFILTER,
+# IPV4_DEVCONF_MEDIUM_ID,
+# IPV4_DEVCONF_NOXFRM,
+# IPV4_DEVCONF_NOPOLICY,
+# IPV4_DEVCONF_FORCE_IGMP_VERSION,
+# IPV4_DEVCONF_ARP_ANNOUNCE,
+# IPV4_DEVCONF_ARP_IGNORE,
+# IPV4_DEVCONF_PROMOTE_SECONDARIES,
+# IPV4_DEVCONF_ARP_ACCEPT,
+# IPV4_DEVCONF_ARP_NOTIFY,
+# IPV4_DEVCONF_ACCEPT_LOCAL,
+# IPV4_DEVCONF_SRC_VMARK,
+# IPV4_DEVCONF_PROXY_ARP_PVLAN,
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/vlan.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/vlan.py
new file mode 100644
index 0000000..0ba3781
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/links/vlan.py
@@ -0,0 +1,71 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""VLAN network link
+
+"""
+
+from __future__ import absolute_import
+
+
+from ... import core as netlink
+from .. import capi as capi
+class VLANLink(object):
+ def __init__(self, link):
+ self._link = link
+
+ @property
+ @netlink.nlattr(type=int)
+ def id(self):
+ """vlan identifier"""
+ return capi.rtnl_link_vlan_get_id(self._link)
+
+ @id.setter
+ def id(self, value):
+ capi.rtnl_link_vlan_set_id(self._link, int(value))
+
+ @property
+ @netlink.nlattr(type=str)
+ def flags(self):
+ """ VLAN flags
+ Setting this property will *Not* reset flags to value you supply in
+ Examples:
+ link.flags = '+xxx' # add xxx flag
+ link.flags = 'xxx' # exactly the same
+ link.flags = '-xxx' # remove xxx flag
+ link.flags = [ '+xxx', '-yyy' ] # list operation
+ """
+ flags = capi.rtnl_link_vlan_get_flags(self._link)
+ return capi.rtnl_link_vlan_flags2str(flags, 256)[0].split(',')
+
+ def _set_flag(self, flag):
+ if flag.startswith('-'):
+ i = capi.rtnl_link_vlan_str2flags(flag[1:])
+ capi.rtnl_link_vlan_unset_flags(self._link, i)
+ elif flag.startswith('+'):
+ i = capi.rtnl_link_vlan_str2flags(flag[1:])
+ capi.rtnl_link_vlan_set_flags(self._link, i)
+ else:
+ i = capi.rtnl_link_vlan_str2flags(flag)
+ capi.rtnl_link_vlan_set_flags(self._link, i)
+
+ @flags.setter
+ def flags(self, value):
+ if type(value) is list:
+ for flag in value:
+ self._set_flag(flag)
+ else:
+ self._set_flag(value)
+
+ ###################################################################
+ # TODO:
+ # - ingress map
+ # - egress map
+
+ def brief(self):
+ return 'vlan-id {0}'.format(self.id)
+
+def init(link):
+ link.vlan = VLANLink(link._rtnl_link)
+ return link.vlan
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/qdisc/__init__.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/qdisc/__init__.py
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/qdisc/__init__.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/qdisc/htb.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/qdisc/htb.py
new file mode 100644
index 0000000..d051c8d
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/qdisc/htb.py
@@ -0,0 +1,145 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""HTB qdisc
+
+"""
+
+from __future__ import absolute_import
+
+from ... import core as netlink
+from ... import util as util
+from .. import capi as capi
+from .. import tc as tc
+
+class HTBQdisc(object):
+ def __init__(self, qdisc):
+ self._qdisc = qdisc
+
+ @property
+ @netlink.nlattr(type=int)
+ def default_class(self):
+ return tc.Handle(capi.rtnl_htb_get_defcls(self._qdisc._rtnl_qdisc))
+
+ @default_class.setter
+ def default_class(self, value):
+ capi.rtnl_htb_set_defcls(self._qdisc._rtnl_qdisc, int(value))
+
+ @property
+ @netlink.nlattr('r2q', type=int)
+ def r2q(self):
+ return capi.rtnl_htb_get_rate2quantum(self._qdisc._rtnl_qdisc)
+
+ @r2q.setter
+ def r2q(self, value):
+ capi.rtnl_htb_get_rate2quantum(self._qdisc._rtnl_qdisc,
+ int(value))
+
+ def brief(self):
+ fmt = util.MyFormatter(self)
+
+ ret = ' {s|default-class!k} {a|default_class}'
+
+ if self.r2q:
+ ret += ' {s|r2q!k} {a|r2q}'
+
+ return fmt.format(ret)
+
+class HTBClass(object):
+ def __init__(self, cl):
+ self._class = cl
+
+ @property
+ @netlink.nlattr(type=str)
+ def rate(self):
+ rate = capi.rtnl_htb_get_rate(self._class._rtnl_class)
+ return util.Rate(rate)
+
+ @rate.setter
+ def rate(self, value):
+ capi.rtnl_htb_set_rate(self._class._rtnl_class, int(value))
+
+ @property
+ @netlink.nlattr(type=str)
+ def ceil(self):
+ ceil = capi.rtnl_htb_get_ceil(self._class._rtnl_class)
+ return util.Rate(ceil)
+
+ @ceil.setter
+ def ceil(self, value):
+ capi.rtnl_htb_set_ceil(self._class._rtnl_class, int(value))
+
+ @property
+ @netlink.nlattr(type=str)
+ def burst(self):
+ burst = capi.rtnl_htb_get_rbuffer(self._class._rtnl_class)
+ return util.Size(burst)
+
+ @burst.setter
+ def burst(self, value):
+ capi.rtnl_htb_set_rbuffer(self._class._rtnl_class, int(value))
+
+ @property
+ @netlink.nlattr(type=str)
+ def ceil_burst(self):
+ burst = capi.rtnl_htb_get_cbuffer(self._class._rtnl_class)
+ return util.Size(burst)
+
+ @ceil_burst.setter
+ def ceil_burst(self, value):
+ capi.rtnl_htb_set_cbuffer(self._class._rtnl_class, int(value))
+
+ @property
+ @netlink.nlattr(type=int)
+ def prio(self):
+ return capi.rtnl_htb_get_prio(self._class._rtnl_class)
+
+ @prio.setter
+ def prio(self, value):
+ capi.rtnl_htb_set_prio(self._class._rtnl_class, int(value))
+
+ @property
+ @netlink.nlattr(type=int)
+ def quantum(self):
+ return capi.rtnl_htb_get_quantum(self._class._rtnl_class)
+
+ @quantum.setter
+ def quantum(self, value):
+ capi.rtnl_htb_set_quantum(self._class._rtnl_class, int(value))
+
+ @property
+ @netlink.nlattr(type=int)
+ def level(self):
+ return capi.rtnl_htb_get_level(self._class._rtnl_class)
+
+ @level.setter
+ def level(self, value):
+ capi.rtnl_htb_set_level(self._class._rtnl_class, int(value))
+
+ def brief(self):
+ fmt = util.MyFormatter(self)
+
+ ret = ' {t|prio} {t|rate}'
+
+ if self.rate != self.ceil:
+ ret += ' {s|borrow-up-to!k} {a|ceil}'
+
+ ret += ' {t|burst}'
+
+ return fmt.format(ret)
+
+ def details(self):
+ fmt = util.MyFormatter(self)
+
+ return fmt.nl('\t{t|level} {t|quantum}')
+
+def init_qdisc(qdisc):
+ qdisc.htb = HTBQdisc(qdisc)
+ return qdisc.htb
+
+def init_class(cl):
+ cl.htb = HTBClass(cl)
+ return cl.htb
+
+#extern void rtnl_htb_set_quantum(struct rtnl_class *, uint32_t quantum);
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/route/tc.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/tc.py
new file mode 100644
index 0000000..0689b71
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/route/tc.py
@@ -0,0 +1,595 @@
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+from __future__ import absolute_import
+
+__all__ = [
+ 'TcCache',
+ 'Tc',
+ 'QdiscCache',
+ 'Qdisc',
+ 'TcClassCache',
+ 'TcClass',
+]
+
+from .. import core as netlink
+from . import capi as capi
+from .. import util as util
+from . import link as Link
+
+TC_PACKETS = 0
+TC_BYTES = 1
+TC_RATE_BPS = 2
+TC_RATE_PPS = 3
+TC_QLEN = 4
+TC_BACKLOG = 5
+TC_DROPS = 6
+TC_REQUEUES = 7
+TC_OVERLIMITS = 9
+
+TC_H_ROOT = 0xFFFFFFFF
+TC_H_INGRESS = 0xFFFFFFF1
+
+STAT_PACKETS = 0
+STAT_BYTES = 1
+STAT_RATE_BPS = 2
+STAT_RATE_PPS = 3
+STAT_QLEN = 4
+STAT_BACKLOG = 5
+STAT_DROPS = 6
+STAT_REQUEUES = 7
+STAT_OVERLIMITS = 8
+STAT_MAX = STAT_OVERLIMITS
+
+
+class Handle(object):
+ """ Traffic control handle
+
+ Representation of a traffic control handle which uniquely identifies
+ each traffic control object in its link namespace.
+
+ handle = tc.Handle('10:20')
+ handle = tc.handle('root')
+ print int(handle)
+ print str(handle)
+ """
+ def __init__(self, val=None):
+ if type(val) is str:
+ val = capi.tc_str2handle(val)
+ elif not val:
+ val = 0
+
+ self._val = int(val)
+
+ def __cmp__(self, other):
+ if other is None:
+ other = 0
+
+ if isinstance(other, Handle):
+ return int(self) - int(other)
+ elif isinstance(other, int):
+ return int(self) - other
+ else:
+ raise TypeError()
+
+ def __int__(self):
+ return self._val
+
+ def __str__(self):
+ return capi.rtnl_tc_handle2str(self._val, 64)[0]
+
+ def isroot(self):
+ return self._val == TC_H_ROOT or self._val == TC_H_INGRESS
+
+class TcCache(netlink.Cache):
+ """Cache of traffic control object"""
+
+ def __getitem__(self, key):
+ raise NotImplementedError()
+
+class Tc(netlink.Object):
+ def __cmp__(self, other):
+ diff = self.ifindex - other.ifindex
+ if diff == 0:
+ diff = int(self.handle) - int(other.handle)
+ return diff
+
+ def _tc_module_lookup(self):
+ self._module_lookup(self._module_path + self.kind,
+ 'init_' + self._name)
+
+ @property
+ def root(self):
+ """True if tc object is a root object"""
+ return self.parent.isroot()
+
+ @property
+ def ifindex(self):
+ """interface index"""
+ return capi.rtnl_tc_get_ifindex(self._rtnl_tc)
+
+ @ifindex.setter
+ def ifindex(self, value):
+ capi.rtnl_tc_set_ifindex(self._rtnl_tc, int(value))
+
+ @property
+ def link(self):
+ link = capi.rtnl_tc_get_link(self._rtnl_tc)
+ if not link:
+ return None
+
+ return Link.Link.from_capi(link)
+
+ @link.setter
+ def link(self, value):
+ capi.rtnl_tc_set_link(self._rtnl_tc, value._link)
+
+ @property
+ def mtu(self):
+ return capi.rtnl_tc_get_mtu(self._rtnl_tc)
+
+ @mtu.setter
+ def mtu(self, value):
+ capi.rtnl_tc_set_mtu(self._rtnl_tc, int(value))
+
+ @property
+ def mpu(self):
+ return capi.rtnl_tc_get_mpu(self._rtnl_tc)
+
+ @mpu.setter
+ def mpu(self, value):
+ capi.rtnl_tc_set_mpu(self._rtnl_tc, int(value))
+
+ @property
+ def overhead(self):
+ return capi.rtnl_tc_get_overhead(self._rtnl_tc)
+
+ @overhead.setter
+ def overhead(self, value):
+ capi.rtnl_tc_set_overhead(self._rtnl_tc, int(value))
+
+ @property
+ def linktype(self):
+ return capi.rtnl_tc_get_linktype(self._rtnl_tc)
+
+ @linktype.setter
+ def linktype(self, value):
+ capi.rtnl_tc_set_linktype(self._rtnl_tc, int(value))
+
+ @property
+ @netlink.nlattr(fmt=util.handle)
+ def handle(self):
+ return Handle(capi.rtnl_tc_get_handle(self._rtnl_tc))
+
+ @handle.setter
+ def handle(self, value):
+ capi.rtnl_tc_set_handle(self._rtnl_tc, int(value))
+
+ @property
+ @netlink.nlattr(fmt=util.handle)
+ def parent(self):
+ return Handle(capi.rtnl_tc_get_parent(self._rtnl_tc))
+
+ @parent.setter
+ def parent(self, value):
+ capi.rtnl_tc_set_parent(self._rtnl_tc, int(value))
+
+ @property
+ @netlink.nlattr(fmt=util.bold)
+ def kind(self):
+ return capi.rtnl_tc_get_kind(self._rtnl_tc)
+
+ @kind.setter
+ def kind(self, value):
+ capi.rtnl_tc_set_kind(self._rtnl_tc, value)
+ self._tc_module_lookup()
+
+ def get_stat(self, id):
+ return capi.rtnl_tc_get_stat(self._rtnl_tc, id)
+
+ @property
+ def _dev(self):
+ buf = util.kw('dev') + ' '
+
+ if self.link:
+ return buf + util.string(self.link.name)
+ else:
+ return buf + util.num(self.ifindex)
+
+ def brief(self, title, nodev=False, noparent=False):
+ ret = title + ' {a|kind} {a|handle}'
+
+ if not nodev:
+ ret += ' {a|_dev}'
+
+ if not noparent:
+ ret += ' {t|parent}'
+
+ return ret + self._module_brief()
+
+ @staticmethod
+ def details():
+ return '{t|mtu} {t|mpu} {t|overhead} {t|linktype}'
+
+ @property
+ def packets(self):
+ return self.get_stat(STAT_PACKETS)
+
+ @property
+ def bytes(self):
+ return self.get_stat(STAT_BYTES)
+
+ @property
+ def qlen(self):
+ return self.get_stat(STAT_QLEN)
+
+ @staticmethod
+ def stats(fmt):
+ return fmt.nl('{t|packets} {t|bytes} {t|qlen}')
+
+class QdiscCache(netlink.Cache):
+ """Cache of qdiscs"""
+
+ def __init__(self, cache=None):
+ if not cache:
+ cache = self._alloc_cache_name('route/qdisc')
+
+ self._protocol = netlink.NETLINK_ROUTE
+ self._nl_cache = cache
+
+# def __getitem__(self, key):
+# if type(key) is int:
+# link = capi.rtnl_link_get(self._this, key)
+# elif type(key) is str:
+# link = capi.rtnl_link_get_by_name(self._this, key)
+#
+# if qdisc is None:
+# raise KeyError()
+# else:
+# return Qdisc._from_capi(capi.qdisc2obj(qdisc))
+
+ @staticmethod
+ def _new_object(obj):
+ return Qdisc(obj)
+
+ @staticmethod
+ def _new_cache(cache):
+ return QdiscCache(cache=cache)
+
+class Qdisc(Tc):
+ """Queueing discipline"""
+
+ def __init__(self, obj=None):
+ netlink.Object.__init__(self, 'route/qdisc', 'qdisc', obj)
+ self._module_path = 'netlink.route.qdisc.'
+ self._rtnl_qdisc = self._obj2type(self._nl_object)
+ self._rtnl_tc = capi.obj2tc(self._nl_object)
+
+ if self.kind:
+ self._tc_module_lookup()
+
+ @classmethod
+ def from_capi(cls, obj):
+ return cls(capi.qdisc2obj(obj))
+
+ @staticmethod
+ def _obj2type(obj):
+ return capi.obj2qdisc(obj)
+
+ @staticmethod
+ def _new_instance(obj):
+ if not obj:
+ raise ValueError()
+
+ return Qdisc(obj)
+
+ @property
+ def childs(self):
+ ret = []
+
+ if int(self.handle):
+ ret += get_cls(self.ifindex, parent=self.handle)
+
+ if self.root:
+ ret += get_class(self.ifindex, parent=TC_H_ROOT)
+
+ ret += get_class(self.ifindex, parent=self.handle)
+
+ return ret
+
+# def add(self, socket, flags=None):
+# if not flags:
+# flags = netlink.NLM_F_CREATE
+#
+# ret = capi.rtnl_link_add(socket._sock, self._link, flags)
+# if ret < 0:
+# raise netlink.KernelError(ret)
+#
+# def change(self, socket, flags=0):
+# """Commit changes made to the link object"""
+# if not self._orig:
+# raise NetlinkError('Original link not available')
+# ret = capi.rtnl_link_change(socket._sock, self._orig, self._link, flags)
+# if ret < 0:
+# raise netlink.KernelError(ret)
+#
+# def delete(self, socket):
+# """Attempt to delete this link in the kernel"""
+# ret = capi.rtnl_link_delete(socket._sock, self._link)
+# if ret < 0:
+# raise netlink.KernelError(ret)
+
+ def format(self, details=False, stats=False, nodev=False,
+ noparent=False, indent=''):
+ """Return qdisc as formatted text"""
+ fmt = util.MyFormatter(self, indent)
+
+ buf = fmt.format(self.brief('qdisc', nodev, noparent))
+
+ if details:
+ buf += fmt.nl('\t' + self.details())
+
+ if stats:
+ buf += self.stats(fmt)
+
+# if stats:
+# l = [['Packets', RX_PACKETS, TX_PACKETS],
+# ['Bytes', RX_BYTES, TX_BYTES],
+# ['Errors', RX_ERRORS, TX_ERRORS],
+# ['Dropped', RX_DROPPED, TX_DROPPED],
+# ['Compressed', RX_COMPRESSED, TX_COMPRESSED],
+# ['FIFO Errors', RX_FIFO_ERR, TX_FIFO_ERR],
+# ['Length Errors', RX_LEN_ERR, None],
+# ['Over Errors', RX_OVER_ERR, None],
+# ['CRC Errors', RX_CRC_ERR, None],
+# ['Frame Errors', RX_FRAME_ERR, None],
+# ['Missed Errors', RX_MISSED_ERR, None],
+# ['Abort Errors', None, TX_ABORT_ERR],
+# ['Carrier Errors', None, TX_CARRIER_ERR],
+# ['Heartbeat Errors', None, TX_HBEAT_ERR],
+# ['Window Errors', None, TX_WIN_ERR],
+# ['Collisions', None, COLLISIONS],
+# ['Multicast', None, MULTICAST],
+# ['', None, None],
+# ['Ipv6:', None, None],
+# ['Packets', IP6_INPKTS, IP6_OUTPKTS],
+# ['Bytes', IP6_INOCTETS, IP6_OUTOCTETS],
+# ['Discards', IP6_INDISCARDS, IP6_OUTDISCARDS],
+# ['Multicast Packets', IP6_INMCASTPKTS, IP6_OUTMCASTPKTS],
+# ['Multicast Bytes', IP6_INMCASTOCTETS, IP6_OUTMCASTOCTETS],
+# ['Broadcast Packets', IP6_INBCASTPKTS, IP6_OUTBCASTPKTS],
+# ['Broadcast Bytes', IP6_INBCASTOCTETS, IP6_OUTBCASTOCTETS],
+# ['Delivers', IP6_INDELIVERS, None],
+# ['Forwarded', None, IP6_OUTFORWDATAGRAMS],
+# ['No Routes', IP6_INNOROUTES, IP6_OUTNOROUTES],
+# ['Header Errors', IP6_INHDRERRORS, None],
+# ['Too Big Errors', IP6_INTOOBIGERRORS, None],
+# ['Address Errors', IP6_INADDRERRORS, None],
+# ['Unknown Protocol', IP6_INUNKNOWNPROTOS, None],
+# ['Truncated Packets', IP6_INTRUNCATEDPKTS, None],
+# ['Reasm Timeouts', IP6_REASMTIMEOUT, None],
+# ['Reasm Requests', IP6_REASMREQDS, None],
+# ['Reasm Failures', IP6_REASMFAILS, None],
+# ['Reasm OK', IP6_REASMOKS, None],
+# ['Frag Created', None, IP6_FRAGCREATES],
+# ['Frag Failures', None, IP6_FRAGFAILS],
+# ['Frag OK', None, IP6_FRAGOKS],
+# ['', None, None],
+# ['ICMPv6:', None, None],
+# ['Messages', ICMP6_INMSGS, ICMP6_OUTMSGS],
+# ['Errors', ICMP6_INERRORS, ICMP6_OUTERRORS]]
+#
+# buf += '\n\t%s%s%s%s\n' % (33 * ' ', util.title('RX'),
+# 15 * ' ', util.title('TX'))
+#
+# for row in l:
+# row[0] = util.kw(row[0])
+# row[1] = self.get_stat(row[1]) if row[1] else ''
+# row[2] = self.get_stat(row[2]) if row[2] else ''
+# buf += '\t{0:27} {1:>16} {2:>16}\n'.format(*row)
+
+ return buf
+
+class TcClassCache(netlink.Cache):
+ """Cache of traffic classes"""
+
+ def __init__(self, ifindex, cache=None):
+ if not cache:
+ cache = self._alloc_cache_name('route/class')
+
+ self._protocol = netlink.NETLINK_ROUTE
+ self._nl_cache = cache
+ self._set_arg1(ifindex)
+
+ @staticmethod
+ def _new_object(obj):
+ return TcClass(obj)
+
+ def _new_cache(self, cache):
+ return TcClassCache(self.arg1, cache=cache)
+
+class TcClass(Tc):
+ """Traffic Class"""
+
+ def __init__(self, obj=None):
+ netlink.Object.__init__(self, 'route/class', 'class', obj)
+ self._module_path = 'netlink.route.qdisc.'
+ self._rtnl_class = self._obj2type(self._nl_object)
+ self._rtnl_tc = capi.obj2tc(self._nl_object)
+
+ if self.kind:
+ self._tc_module_lookup()
+
+ @classmethod
+ def from_capi(cls, obj):
+ return cls(capi.class2obj(obj))
+
+ @staticmethod
+ def _obj2type(obj):
+ return capi.obj2class(obj)
+
+ @staticmethod
+ def _new_instance(obj):
+ if not obj:
+ raise ValueError()
+
+ return TcClass(obj)
+
+ @property
+ def childs(self):
+ ret = []
+
+ # classes can have classifiers, child classes and leaf
+ # qdiscs
+ ret += get_cls(self.ifindex, parent=self.handle)
+ ret += get_class(self.ifindex, parent=self.handle)
+ ret += get_qdisc(self.ifindex, parent=self.handle)
+
+ return ret
+
+ def format(self, details=False, _stats=False, nodev=False,
+ noparent=False, indent=''):
+ """Return class as formatted text"""
+ fmt = util.MyFormatter(self, indent)
+
+ buf = fmt.format(self.brief('class', nodev, noparent))
+
+ if details:
+ buf += fmt.nl('\t' + self.details())
+
+ return buf
+
+class ClassifierCache(netlink.Cache):
+ """Cache of traffic classifiers objects"""
+
+ def __init__(self, ifindex, parent, cache=None):
+ if not cache:
+ cache = self._alloc_cache_name('route/cls')
+
+ self._protocol = netlink.NETLINK_ROUTE
+ self._nl_cache = cache
+ self._set_arg1(ifindex)
+ self._set_arg2(int(parent))
+
+ @staticmethod
+ def _new_object(obj):
+ return Classifier(obj)
+
+ def _new_cache(self, cache):
+ return ClassifierCache(self.arg1, self.arg2, cache=cache)
+
+class Classifier(Tc):
+ """Classifier"""
+
+ def __init__(self, obj=None):
+ netlink.Object.__init__(self, 'route/cls', 'cls', obj)
+ self._module_path = 'netlink.route.cls.'
+ self._rtnl_cls = self._obj2type(self._nl_object)
+ self._rtnl_tc = capi.obj2tc(self._nl_object)
+
+ @classmethod
+ def from_capi(cls, obj):
+ return cls(capi.cls2obj(obj))
+
+ @staticmethod
+ def _obj2type(obj):
+ return capi.obj2cls(obj)
+
+ @staticmethod
+ def _new_instance(obj):
+ if not obj:
+ raise ValueError()
+
+ return Classifier(obj)
+
+ @property
+ def priority(self):
+ return capi.rtnl_cls_get_prio(self._rtnl_cls)
+
+ @priority.setter
+ def priority(self, value):
+ capi.rtnl_cls_set_prio(self._rtnl_cls, int(value))
+
+ @property
+ def protocol(self):
+ return capi.rtnl_cls_get_protocol(self._rtnl_cls)
+
+ @protocol.setter
+ def protocol(self, value):
+ capi.rtnl_cls_set_protocol(self._rtnl_cls, int(value))
+
+ @property
+ def childs(self):
+ return []
+
+ def format(self, details=False, _stats=False, nodev=False,
+ noparent=False, indent=''):
+ """Return class as formatted text"""
+ fmt = util.MyFormatter(self, indent)
+
+ buf = fmt.format(self.brief('classifier', nodev, noparent))
+ buf += fmt.format(' {t|priority} {t|protocol}')
+
+ if details:
+ buf += fmt.nl('\t' + self.details())
+
+ return buf
+
+_qdisc_cache = QdiscCache()
+
+def get_qdisc(ifindex, handle=None, parent=None):
+ l = []
+
+ _qdisc_cache.refill()
+
+ for qdisc in _qdisc_cache:
+ if qdisc.ifindex != ifindex:
+ continue
+ if (handle is not None) and (qdisc.handle != handle):
+ continue
+ if (parent is not None) and (qdisc.parent != parent):
+ continue
+ l.append(qdisc)
+
+ return l
+
+_class_cache = {}
+
+def get_class(ifindex, parent, handle=None):
+ l = []
+
+ try:
+ cache = _class_cache[ifindex]
+ except KeyError:
+ cache = TcClassCache(ifindex)
+ _class_cache[ifindex] = cache
+
+ cache.refill()
+
+ for cl in cache:
+ if (parent is not None) and (cl.parent != parent):
+ continue
+ if (handle is not None) and (cl.handle != handle):
+ continue
+ l.append(cl)
+
+ return l
+
+_cls_cache = {}
+
+def get_cls(ifindex, parent, handle=None):
+
+ chain = _cls_cache.get(ifindex, dict())
+
+ try:
+ cache = chain[parent]
+ except KeyError:
+ cache = ClassifierCache(ifindex, parent)
+ chain[parent] = cache
+
+ cache.refill()
+
+ if handle is None:
+ return [ cls for cls in cache ]
+
+ return [ cls for cls in cache if cls.handle == handle ]
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/util.py b/ap/lib/libnl/libnl-3.2.25/python/netlink/util.py
new file mode 100644
index 0000000..22ed5cf
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/util.py
@@ -0,0 +1,175 @@
+#
+# Utilities
+#
+# Copyright (c) 2011 Thomas Graf <tgraf@suug.ch>
+#
+
+"""utility module for netlink
+
+"""
+
+from __future__ import absolute_import
+
+from . import core as netlink
+from . import capi as capi
+from string import Formatter
+import types
+
+__version__ = '1.0'
+
+#rename into colored_output
+def _color(t, c):
+ return '{esc}[{color}m{text}{esc}[0m'.format(esc=b'\x1b'.decode(), color=c, text=t)
+
+def black(t):
+ return _color(t, 30)
+
+def red(t):
+ return _color(t, 31)
+
+def green(t):
+ return _color(t, 32)
+
+def yellow(t):
+ return _color(t, 33)
+
+def blue(t):
+ return _color(t, 34)
+
+def magenta(t):
+ return _color(t, 35)
+
+def cyan(t):
+ return _color(t, 36)
+
+def white(t):
+ return _color(t, 37)
+
+def bold(t):
+ return _color(t, 1)
+
+def kw(t):
+ return yellow(t)
+
+def num(t):
+ return str(t)
+
+def string(t):
+ return t
+
+def addr(t):
+ return str(t)
+
+def bad(t):
+ return red(t)
+
+def good(t):
+ return green(t)
+
+def title(t):
+ return t
+
+def boolean(t):
+ return str(t)
+
+def handle(t):
+ return str(t)
+
+class MyFormatter(Formatter):
+ def __init__(self, obj, indent=''):
+ self._obj = obj
+ self._indent = indent
+
+ def _nlattr(self, key):
+ value = getattr(self._obj.__class__, key)
+ if not isinstance(value, property):
+ raise ValueError('Invalid formatting string {0}'.format(key))
+
+ d = getattr(value.fget, 'formatinfo', dict())
+
+ # value = value.fget() is exactly the same
+ value = getattr(self._obj, key)
+
+ if 'fmt' in d:
+ value = d['fmt'](value)
+
+ title_ = d.get('title', None)
+
+ return title_, str(value)
+
+ def get_value(self, key, args, kwds):
+ # Let default get_value() handle ints
+ if not isinstance(key, str):
+ return Formatter.get_value(self, key, args, kwds)
+
+ # HACK, we allow defining strings via fields to allow
+ # conversions
+ if key[:2] == 's|':
+ return key[2:]
+
+ if key[:2] == 't|':
+ # title mode ("TITLE ATTR")
+ include_title = True
+ elif key[:2] == 'a|':
+ # plain attribute mode ("ATTR")
+ include_title = False
+ else:
+ # No special field, have default get_value() get it
+ return Formatter.get_value(self, key, args, kwds)
+
+ key = key[2:]
+ (title_, value) = self._nlattr(key)
+
+ if include_title:
+ if not title_:
+ title_ = key # fall back to key as title
+ value = '{0} {1}'.format(kw(title_), value)
+
+ return value
+
+ def convert_field(self, value, conversion):
+ if conversion == 'r':
+ return repr(value)
+ elif conversion == 's':
+ return str(value)
+ elif conversion == 'k':
+ return kw(value)
+ elif conversion == 'b':
+ return bold(value)
+ elif conversion is None:
+ return value
+
+ raise ValueError('Unknown converion specifier {0!s}'.format(conversion))
+
+ def nl(self, format_string=''):
+ return '\n' + self._indent + self.format(format_string)
+
+NL_BYTE_RATE = 0
+NL_BIT_RATE = 1
+
+class Rate(object):
+ def __init__(self, rate, mode=NL_BYTE_RATE):
+ self._rate = rate
+ self._mode = mode
+
+ def __str__(self):
+ return capi.nl_rate2str(self._rate, self._mode, 32)[1]
+
+ def __int__(self):
+ return self._rate
+
+ def __cmp__(self, other):
+ return int(self) - int(other)
+
+class Size(object):
+ def __init__(self, size):
+ self._size = size
+
+ def __str__(self):
+ return capi.nl_size2str(self._size, 32)[0]
+
+ def __int__(self):
+ return self._size
+
+ def __cmp__(self, other):
+ return int(self) - int(other)
diff --git a/ap/lib/libnl/libnl-3.2.25/python/netlink/utils.h b/ap/lib/libnl/libnl-3.2.25/python/netlink/utils.h
new file mode 100644
index 0000000..7836c30
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/netlink/utils.h
@@ -0,0 +1,41 @@
+struct list_head {
+ struct list_head *next;
+};
+
+#define LIST_HEAD(name) \
+ struct list_head name = { &(name) }
+
+static inline int list_empty(const struct list_head *head)
+{
+ return head->next == head;
+}
+
+static inline void list_add(struct list_head *new, struct list_head *head)
+{
+ new->next = head->next;
+ head->next = new;
+}
+
+static inline void list_del(struct list_head *entry, struct list_head *prev)
+{
+ prev->next = entry->next;
+ entry->next = entry;
+}
+
+#define list_for_each_safe(pos, n, head) \
+ for (n = (head), pos = (head)->next; pos != (head); \
+ n = pos, pos = n->next)
+
+#undef offsetof
+#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
+
+#define container_of(ptr, type, member) ({ \
+ const typeof( ((type *)0)->member ) *__mptr = (ptr); \
+ (type *)( (char *)__mptr - offsetof(type,member) );})
+
+#ifdef DEBUG
+#define pynl_dbg(fmt, ...) \
+ fprintf(stderr, "%s: " fmt, __func__, __VA_ARGS__)
+#else
+#define pynl_dbg(fmt, ...)
+#endif
diff --git a/ap/lib/libnl/libnl-3.2.25/python/setup.py.in b/ap/lib/libnl/libnl-3.2.25/python/setup.py.in
new file mode 100644
index 0000000..346c770
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/setup.py.in
@@ -0,0 +1,42 @@
+#!/usr/bin/env python
+
+from distutils.core import setup, Extension
+
+opts = ['-O', '-nodefaultctor']
+include = ['@top_builddir@/include', '@top_srcdir@/include']
+library_dirs = ['@top_builddir@/lib/.libs']
+
+netlink_capi = Extension('netlink/_capi',
+ sources = ['@srcdir@/netlink/capi.i'],
+ include_dirs = include,
+ swig_opts = opts,
+ library_dirs = library_dirs,
+ libraries = ['nl-3'],
+ )
+
+route_capi = Extension('netlink/route/_capi',
+ sources = ['@srcdir@/netlink/route/capi.i'],
+ include_dirs = include,
+ swig_opts = opts,
+ library_dirs = library_dirs,
+ libraries = ['nl-3', 'nl-route-3'],
+ )
+
+genl_capi = Extension('netlink/genl/_capi',
+ sources = ['@srcdir@/netlink/genl/capi.i'],
+ include_dirs = include,
+ swig_opts = opts,
+ library_dirs = library_dirs,
+ libraries = ['nl-3', 'nl-genl-3'],
+ )
+
+setup(name = 'netlink',
+ version = '1.0',
+ description = 'Python wrapper for netlink protocols',
+ author = 'Thomas Graf',
+ author_email = 'tgraf@suug.ch',
+ ext_modules = [netlink_capi, route_capi, genl_capi],
+ package_dir = {'': '@srcdir@'},
+ packages = ['netlink', 'netlink.genl', 'netlink.route',
+ 'netlink.route.links', 'netlink.route.qdisc'],
+ )
diff --git a/ap/lib/libnl/libnl-3.2.25/python/tests/Makefile.am b/ap/lib/libnl/libnl-3.2.25/python/tests/Makefile.am
new file mode 100644
index 0000000..15f77fa
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/tests/Makefile.am
@@ -0,0 +1,5 @@
+
+# -*- Makefile -*-
+
+EXTRA_DIST = \
+ test-create-bridge.py
diff --git a/ap/lib/libnl/libnl-3.2.25/python/tests/Makefile.in b/ap/lib/libnl/libnl-3.2.25/python/tests/Makefile.in
new file mode 100644
index 0000000..ef343c9
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/tests/Makefile.in
@@ -0,0 +1,442 @@
+# Makefile.in generated by automake 1.13.4 from Makefile.am.
+# @configure_input@
+
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
+
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+@SET_MAKE@
+
+# -*- Makefile -*-
+VPATH = @srcdir@
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+ case $${target_option-} in \
+ ?) ;; \
+ *) echo "am__make_running_with_option: internal error: invalid" \
+ "target option '$${target_option-}' specified" >&2; \
+ exit 1;; \
+ esac; \
+ has_opt=no; \
+ sane_makeflags=$$MAKEFLAGS; \
+ if $(am__is_gnu_make); then \
+ sane_makeflags=$$MFLAGS; \
+ else \
+ case $$MAKEFLAGS in \
+ *\\[\ \ ]*) \
+ bs=\\; \
+ sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+ | sed "s/$$bs$$bs[$$bs $$bs ]*//g"`;; \
+ esac; \
+ fi; \
+ skip_next=no; \
+ strip_trailopt () \
+ { \
+ flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+ }; \
+ for flg in $$sane_makeflags; do \
+ test $$skip_next = yes && { skip_next=no; continue; }; \
+ case $$flg in \
+ *=*|--*) continue;; \
+ -*I) strip_trailopt 'I'; skip_next=yes;; \
+ -*I?*) strip_trailopt 'I';; \
+ -*O) strip_trailopt 'O'; skip_next=yes;; \
+ -*O?*) strip_trailopt 'O';; \
+ -*l) strip_trailopt 'l'; skip_next=yes;; \
+ -*l?*) strip_trailopt 'l';; \
+ -[dEDm]) skip_next=yes;; \
+ -[JT]) skip_next=yes;; \
+ esac; \
+ case $$flg in \
+ *$$target_option*) has_opt=yes; break;; \
+ esac; \
+ done; \
+ test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
+pkgdatadir = $(datadir)/@PACKAGE@
+pkgincludedir = $(includedir)/@PACKAGE@
+pkglibdir = $(libdir)/@PACKAGE@
+pkglibexecdir = $(libexecdir)/@PACKAGE@
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = @build@
+host_triplet = @host@
+subdir = python/tests
+DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/m4/libtool.m4 \
+ $(top_srcdir)/m4/ltoptions.m4 $(top_srcdir)/m4/ltsugar.m4 \
+ $(top_srcdir)/m4/ltversion.m4 $(top_srcdir)/m4/lt~obsolete.m4 \
+ $(top_srcdir)/configure.ac
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/lib/defs.h
+CONFIG_CLEAN_FILES =
+CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_@AM_V@)
+am__v_P_ = $(am__v_P_@AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_@AM_V@)
+am__v_GEN_ = $(am__v_GEN_@AM_DEFAULT_V@)
+am__v_GEN_0 = @echo " GEN " $@;
+am__v_GEN_1 =
+AM_V_at = $(am__v_at_@AM_V@)
+am__v_at_ = $(am__v_at_@AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 =
+SOURCES =
+DIST_SOURCES =
+am__can_run_installinfo = \
+ case $$AM_UPDATE_INFO_DIR in \
+ n|no|NO) false;; \
+ *) (install-info --version) >/dev/null 2>&1;; \
+ esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACLOCAL = @ACLOCAL@
+AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
+AR = @AR@
+AUTOCONF = @AUTOCONF@
+AUTOHEADER = @AUTOHEADER@
+AUTOMAKE = @AUTOMAKE@
+AWK = @AWK@
+CC = @CC@
+CCDEPMODE = @CCDEPMODE@
+CFLAGS = @CFLAGS@
+CHECK_CFLAGS = @CHECK_CFLAGS@
+CHECK_LIBS = @CHECK_LIBS@
+CPP = @CPP@
+CPPFLAGS = @CPPFLAGS@
+CYGPATH_W = @CYGPATH_W@
+DEFS = @DEFS@
+DEPDIR = @DEPDIR@
+DLLTOOL = @DLLTOOL@
+DSYMUTIL = @DSYMUTIL@
+DUMPBIN = @DUMPBIN@
+ECHO_C = @ECHO_C@
+ECHO_N = @ECHO_N@
+ECHO_T = @ECHO_T@
+EGREP = @EGREP@
+EXEEXT = @EXEEXT@
+FGREP = @FGREP@
+FLEX = @FLEX@
+GREP = @GREP@
+INSTALL = @INSTALL@
+INSTALL_DATA = @INSTALL_DATA@
+INSTALL_PROGRAM = @INSTALL_PROGRAM@
+INSTALL_SCRIPT = @INSTALL_SCRIPT@
+INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@
+LD = @LD@
+LDFLAGS = @LDFLAGS@
+LIBNL_VERSION = @LIBNL_VERSION@
+LIBOBJS = @LIBOBJS@
+LIBS = @LIBS@
+LIBTOOL = @LIBTOOL@
+LIPO = @LIPO@
+LN_S = @LN_S@
+LTLIBOBJS = @LTLIBOBJS@
+LT_AGE = @LT_AGE@
+LT_CURRENT = @LT_CURRENT@
+LT_REVISION = @LT_REVISION@
+MAJ_VERSION = @MAJ_VERSION@
+MAKEINFO = @MAKEINFO@
+MANIFEST_TOOL = @MANIFEST_TOOL@
+MIC_VERSION = @MIC_VERSION@
+MIN_VERSION = @MIN_VERSION@
+MKDIR_P = @MKDIR_P@
+NM = @NM@
+NMEDIT = @NMEDIT@
+OBJDUMP = @OBJDUMP@
+OBJEXT = @OBJEXT@
+OTOOL = @OTOOL@
+OTOOL64 = @OTOOL64@
+PACKAGE = @PACKAGE@
+PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@
+PACKAGE_NAME = @PACKAGE_NAME@
+PACKAGE_STRING = @PACKAGE_STRING@
+PACKAGE_TARNAME = @PACKAGE_TARNAME@
+PACKAGE_URL = @PACKAGE_URL@
+PACKAGE_VERSION = @PACKAGE_VERSION@
+PATH_SEPARATOR = @PATH_SEPARATOR@
+PKG_CONFIG = @PKG_CONFIG@
+PKG_CONFIG_LIBDIR = @PKG_CONFIG_LIBDIR@
+PKG_CONFIG_PATH = @PKG_CONFIG_PATH@
+RANLIB = @RANLIB@
+SED = @SED@
+SET_MAKE = @SET_MAKE@
+SHELL = @SHELL@
+STRIP = @STRIP@
+VERSION = @VERSION@
+YACC = @YACC@
+abs_builddir = @abs_builddir@
+abs_srcdir = @abs_srcdir@
+abs_top_builddir = @abs_top_builddir@
+abs_top_srcdir = @abs_top_srcdir@
+ac_ct_AR = @ac_ct_AR@
+ac_ct_CC = @ac_ct_CC@
+ac_ct_DUMPBIN = @ac_ct_DUMPBIN@
+am__include = @am__include@
+am__leading_dot = @am__leading_dot@
+am__quote = @am__quote@
+am__tar = @am__tar@
+am__untar = @am__untar@
+bindir = @bindir@
+build = @build@
+build_alias = @build_alias@
+build_cpu = @build_cpu@
+build_os = @build_os@
+build_vendor = @build_vendor@
+builddir = @builddir@
+datadir = @datadir@
+datarootdir = @datarootdir@
+docdir = @docdir@
+dvidir = @dvidir@
+exec_prefix = @exec_prefix@
+host = @host@
+host_alias = @host_alias@
+host_cpu = @host_cpu@
+host_os = @host_os@
+host_vendor = @host_vendor@
+htmldir = @htmldir@
+includedir = @includedir@
+infodir = @infodir@
+install_sh = @install_sh@
+libdir = @libdir@
+libexecdir = @libexecdir@
+localedir = @localedir@
+localstatedir = @localstatedir@
+mandir = @mandir@
+mkdir_p = @mkdir_p@
+oldincludedir = @oldincludedir@
+pdfdir = @pdfdir@
+pkgconfigdir = @pkgconfigdir@
+prefix = @prefix@
+program_transform_name = @program_transform_name@
+psdir = @psdir@
+sbindir = @sbindir@
+sharedstatedir = @sharedstatedir@
+srcdir = @srcdir@
+subdirs = @subdirs@
+sysconfdir = @sysconfdir@
+target_alias = @target_alias@
+top_build_prefix = @top_build_prefix@
+top_builddir = @top_builddir@
+top_srcdir = @top_srcdir@
+EXTRA_DIST = \
+ test-create-bridge.py
+
+all: all-am
+
+.SUFFIXES:
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \
+ && { if test -f $@; then exit 0; else break; fi; }; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign python/tests/Makefile'; \
+ $(am__cd) $(top_srcdir) && \
+ $(AUTOMAKE) --foreign python/tests/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(am__aclocal_m4_deps):
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+tags TAGS:
+
+ctags CTAGS:
+
+cscope cscopelist:
+
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
+ list='$(DISTFILES)'; \
+ dist_files=`for file in $$list; do echo $$file; done | \
+ sed -e "s|^$$srcdirstrip/||;t" \
+ -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \
+ case $$dist_files in \
+ */*) $(MKDIR_P) `echo "$$dist_files" | \
+ sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \
+ sort -u` ;; \
+ esac; \
+ for file in $$dist_files; do \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ if test -d $$d/$$file; then \
+ dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test -d "$(distdir)/$$file"; then \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \
+ find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \
+ fi; \
+ cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \
+ else \
+ test -f "$(distdir)/$$file" \
+ || cp -p $$d/$$file "$(distdir)/$$file" \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile
+installdirs:
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ if test -z '$(STRIP)'; then \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ install; \
+ else \
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
+ fi
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+ -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libtool mostlyclean-am
+
+distclean: distclean-am
+ -rm -f Makefile
+distclean-am: clean-am distclean-generic
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+html-am:
+
+info: info-am
+
+info-am:
+
+install-data-am:
+
+install-dvi: install-dvi-am
+
+install-dvi-am:
+
+install-exec-am:
+
+install-html: install-html-am
+
+install-html-am:
+
+install-info: install-info-am
+
+install-info-am:
+
+install-man:
+
+install-pdf: install-pdf-am
+
+install-pdf-am:
+
+install-ps: install-ps-am
+
+install-ps-am:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-generic mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am:
+
+.MAKE: install-am install-strip
+
+.PHONY: all all-am check check-am clean clean-generic clean-libtool \
+ cscopelist-am ctags-am distclean distclean-generic \
+ distclean-libtool distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-dvi \
+ install-dvi-am install-exec install-exec-am install-html \
+ install-html-am install-info install-info-am install-man \
+ install-pdf install-pdf-am install-ps install-ps-am \
+ install-strip installcheck installcheck-am installdirs \
+ maintainer-clean maintainer-clean-generic mostlyclean \
+ mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
+ tags-am uninstall uninstall-am
+
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
diff --git a/ap/lib/libnl/libnl-3.2.25/python/tests/test-create-bridge.py b/ap/lib/libnl/libnl-3.2.25/python/tests/test-create-bridge.py
new file mode 100644
index 0000000..216b249
--- /dev/null
+++ b/ap/lib/libnl/libnl-3.2.25/python/tests/test-create-bridge.py
@@ -0,0 +1,28 @@
+import netlink.core as netlink
+import netlink.route.capi as capi
+import netlink.route.link as link
+
+sock = netlink.lookup_socket(netlink.NETLINK_ROUTE)
+
+cache = link.LinkCache()
+cache.refill(sock)
+
+testtap1 = cache['testtap1']
+print testtap1
+
+lbr = link.Link()
+lbr.type = 'bridge'
+lbr.name = 'testbridge'
+print lbr
+lbr.add()
+
+cache.refill(sock)
+lbr = cache['testbridge']
+print lbr
+
+lbr.enslave(testtap1)
+cache.refill(sock)
+testtap1 = cache['testtap1']
+
+print capi.rtnl_link_is_bridge(lbr._rtnl_link)
+print capi.rtnl_link_get_master(testtap1._rtnl_link)