debian/0000755000000000000000000000000012032372636007172 5ustar debian/copyright0000644000000000000000000000324211707553673011140 0ustar Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?op=file&rev=166 Upstream-Name: crda Upstream-Contact: Luis R. Rodriguez Source: git://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/crda.git Files: * Copyright: 2008, Luis R. Rodriguez 2008, Johannes Berg 2008, Michael Green License: ISC Files: nl80211.h Copyright: 2006-2008 Johannes Berg 2008 Michael Wu 2008 Luis Carlos Cobo 2008 Michael Buesch 2008 Luis R. Rodriguez 2008 Jouni Malinen 2008 Colin McCabe License: ISC Files: debian/* Copyright: 2009, Kel Modderman 2011, Stefan Lippers-Hollmann License: ISC License: ISC Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. . THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. debian/crda.default0000644000000000000000000000104511707553673011463 0ustar # Set REGDOMAIN to a ISO/IEC 3166-1 alpha2 country code so that iw(8) may set # the initial regulatory domain setting for IEEE 802.11 devices which operate # on this system. # # Governments assert the right to regulate usage of radio spectrum within # their respective territories so make sure you select a ISO/IEC 3166-1 alpha2 # country code suitable for your location or you may infringe on local # legislature. See `/usr/share/zoneinfo/zone.tab' for a table of timezone # descriptions containing ISO/IEC 3166-1 alpha2 country codes. REGDOMAIN= debian/source/0000755000000000000000000000000011707574743010505 5ustar debian/source/format0000644000000000000000000000001411707553673011712 0ustar 3.0 (quilt) debian/changelog0000644000000000000000000000473012032372636011050 0ustar crda (1.1.2-1ubuntu2) quantal; urgency=low * Rebuild for new armel compiler default of ARMv5t. -- Colin Watson Mon, 01 Oct 2012 20:57:18 +0100 crda (1.1.2-1ubuntu1) precise; urgency=low * Merge from Debian testing, remaining changes: - Break/replace wireless-crda. - Replace wireless-regdb 2011.04.28-1ubuntu1 and 2011.04.28-1ubuntu2 due to a file conflict. -- Steve Langasek Tue, 24 Jan 2012 10:35:05 -0800 crda (1.1.2-1) unstable; urgency=low * New upstream version [ Stefan Lippers-Hollmann ] * switch to libnl3 3.2 and raise versioned build-dependency to (>= 3.2.3-2~), to be able to expect it in /lib/. * crda is specific to the linux kernel, restrict it to linux-any. * bump standards version to 3.9.2, no changes necessary. [ Ben Hutchings ] * debian/control: Add references to git repository * debian/control: Set Multi-Arch: foreign, thanks to Tim Gardner -- Ben Hutchings Thu, 29 Dec 2011 02:41:08 +0100 crda (1.1.1-1ubuntu5) precise; urgency=low * Drop the provides: wireless-crda, as this confuses multiarch apt due to the M-A: foreign field; the real wireless-crda package still in universe that depends on crda satisfies the dep for old kernel packages and the new kernel packages depend on crda directly, so it's no longer needed here anyway. -- Steve Langasek Wed, 11 Jan 2012 17:39:09 +0100 crda (1.1.1-1ubuntu4) precise; urgency=low * debian/control: Build-depend on libnl-genl-3-dev * debian/patches/libnl3.patch: (LP: #908464) - Use pkg-config to determine NLLIBS -- Andreas Moog Sat, 24 Dec 2011 22:28:49 +0100 crda (1.1.1-1ubuntu3) precise; urgency=low * Port to libnl3. -- Colin Watson Sat, 26 Nov 2011 00:13:22 +0000 crda (1.1.1-1ubuntu2) precise; urgency=low * Provide/break/replace wireless-crda. * Replace wireless-regdb 2011.04.28-1ubuntu1 and 2011.04.28-1ubuntu2 due to a file conflict. -- Colin Watson Fri, 25 Nov 2011 20:16:30 +0000 crda (1.1.1-1ubuntu1) precise; urgency=low * Make crda Multi-Arch: foreign -- Tim Gardner Mon, 21 Nov 2011 10:46:55 -0700 crda (1.1.1-1) unstable; urgency=low * Initial release (Closes: #536502) - Most packaging was done by Kel Modderman and Stefan Lippers-Hollmann -- Ben Hutchings Mon, 11 Apr 2011 13:18:35 +0100 debian/watch0000644000000000000000000000011611707553673010233 0ustar version=3 http://wireless.kernel.org/download/crda/crda-(.*)\.tar\.bz2 debian debian/setregdomain0000644000000000000000000000057411707553673011616 0ustar #!/bin/sh set -e REGDOMAIN= CRDA_CONF=/etc/default/crda [ -r "$CRDA_CONF" ] && . "$CRDA_CONF" [ -z "$REGDOMAIN" ] && exit 0 # In the future, iw may be moved to / filesystem [ -x /sbin/iw ] && exec /sbin/iw reg set "$REGDOMAIN" # Wait for /usr, it may not be mounted yet ( . /lib/udev/hotplug.functions wait_for_file /usr/sbin/iw exec /usr/sbin/iw reg set "$REGDOMAIN" ) & debian/patches/0000755000000000000000000000000011707574743010634 5ustar debian/patches/series0000644000000000000000000000010711707570765012047 0ustar do_not_embed_pubkeys.patch crda_add-nested-support-for-libnl-3.2.patch debian/patches/do_not_embed_pubkeys.patch0000644000000000000000000000251211707553673016034 0ustar Description: Allow build without embedding pubkey data into crda/regdbdump binaries. From: Kel Modderman --- a/Makefile +++ b/Makefile @@ -33,7 +33,12 @@ ifeq ($(USE_OPENSSL),1) CFLAGS += -DUSE_OPENSSL -DPUBKEY_DIR=\"$(RUNTIME_PUBKEY_DIR)\" `pkg-config --cflags openssl` LDLIBS += `pkg-config --libs openssl` +ifeq ($(RUNTIME_PUBKEY_ONLY),1) +CFLAGS += -DRUNTIME_PUBKEY_ONLY +else +CFLAGS += -DHAVE_KEYS_SSL reglib.o: keys-ssl.c +endif else CFLAGS += -DUSE_GCRYPT --- a/reglib.c +++ b/reglib.c @@ -18,7 +18,7 @@ #include "reglib.h" -#ifdef USE_OPENSSL +#if defined(USE_OPENSSL) && defined(HAVE_KEYS_SSL) #include "keys-ssl.c" #endif @@ -49,7 +49,6 @@ int crda_verify_db_signature(__u8 *db, i #ifdef USE_OPENSSL RSA *rsa; __u8 hash[SHA_DIGEST_LENGTH]; - unsigned int i; int ok = 0; DIR *pubkey_dir; struct dirent *nextfile; @@ -61,6 +60,8 @@ int crda_verify_db_signature(__u8 *db, i goto out; } +#ifdef HAVE_KEYS_SSL + unsigned int i; for (i = 0; (i < sizeof(keys)/sizeof(keys[0])) && (!ok); i++) { rsa = RSA_new(); if (!rsa) { @@ -78,6 +79,7 @@ int crda_verify_db_signature(__u8 *db, i rsa->n = NULL; RSA_free(rsa); } +#endif if (!ok && (pubkey_dir = opendir(PUBKEY_DIR))) { while (!ok && (nextfile = readdir(pubkey_dir))) { snprintf(filename, PATH_MAX, "%s/%s", PUBKEY_DIR, debian/patches/crda_add-nested-support-for-libnl-3.2.patch0000644000000000000000000000446511707553732020556 0ustar From ac073acee8ce0345c6fc844d1c4a5a8a3d6cfc23 Mon Sep 17 00:00:00 2001 From: Stefan Lippers-Hollmann Date: Mon, 19 Dec 2011 21:14:21 +0100 Subject: [PATCH 5/5] crda: add nested support for libnl-3.2 Skip libnl-3.1 due to broken .pc files. Tested to work with: - libnl-3.2.3 (Debian 3.2.3-1) Changes-licensed-under: ISC Signed-off-by: Stefan Lippers-Hollmann --- Makefile | 25 ++++++++++++++++--------- crda.c | 4 ++-- 2 files changed, 18 insertions(+), 11 deletions(-) diff --git a/Makefile b/Makefile index 084d8e5..5a8ed46 100644 --- a/Makefile +++ b/Makefile @@ -48,19 +48,26 @@ INSTALL ?= install NL1FOUND := $(shell pkg-config --atleast-version=1 libnl-1 && echo Y) NL2FOUND := $(shell pkg-config --atleast-version=2 libnl-2.0 && echo Y) NL3FOUND := $(shell pkg-config --atleast-version=3 libnl-3.0 && echo Y) +NL32FOUND := $(shell pkg-config --atleast-version=3 libnl-3.2 && echo Y) -ifeq ($(NL3FOUND),Y) +ifeq ($(NL32FOUND),Y) CFLAGS += -DCONFIG_LIBNL30 -NLLIBS += -lnl-genl -NLLIBNAME = libnl-3.0 +NLLIBS += $(shell pkg-config --libs libnl-genl-3.2) +NLLIBNAME = libnl-3.2 else - ifeq ($(NL2FOUND),Y) - CFLAGS += -DCONFIG_LIBNL20 - NLLIBS += -lnl-genl - NLLIBNAME = libnl-2.0 + ifeq ($(NL3FOUND),Y) + CFLAGS += -DCONFIG_LIBNL30 + NLLIBS += $(shell pkg-config --libs libnl-genl-3.0) + NLLIBNAME = libnl-3.0 else - ifeq ($(NL1FOUND),Y) - NLLIBNAME = libnl-1 + ifeq ($(NL2FOUND),Y) + CFLAGS += -DCONFIG_LIBNL20 + NLLIBS += -lnl-genl + NLLIBNAME = libnl-2.0 + else + ifeq ($(NL1FOUND),Y) + NLLIBNAME = libnl-1 + endif endif endif endif diff --git a/crda.c b/crda.c index 1e2ff22..1db54a5 100644 --- a/crda.c +++ b/crda.c @@ -21,7 +21,7 @@ #include "regdb.h" #include "reglib.h" -#if !defined(CONFIG_LIBNL20) && !defined(CONFIG_LIBNL30) +#if !defined(CONFIG_LIBNL20) && !defined(CONFIG_LIBNL30) && !defined(CONFIG_LIBNL32) /* libnl 2.0 compatibility code */ static inline struct nl_handle *nl_socket_alloc(void) { @@ -44,7 +44,7 @@ static inline int __genl_ctrl_alloc_cache(struct nl_handle *h, struct nl_cache * #define genl_ctrl_alloc_cache __genl_ctrl_alloc_cache #define nl_sock nl_handle -#endif /* CONFIG_LIBNL20 && CONFIG_LIBNL30 */ +#endif /* CONFIG_LIBNL20 && CONFIG_LIBNL30 && CONFIG_LIBNL32 */ struct nl80211_state { struct nl_sock *nl_sock; -- 1.7.7.3 debian/crda.udev0000644000000000000000000000010511707553673010776 0ustar SUBSYSTEM=="ieee80211", ACTION=="add", RUN+="/lib/crda/setregdomain" debian/control0000644000000000000000000000241311707554113010575 0ustar Source: crda Section: net Priority: optional Maintainer: Ubuntu Developers XSBC-Original-Maintainer: Ben Hutchings Build-Depends: debhelper (>= 8), libnl-3-dev (>= 3.2.3-2~) [linux-any], libnl-genl-3-dev (>= 3.2.3-2~) [linux-any], libssl-dev, pkg-config Standards-Version: 3.9.2 Vcs-Git: git://git.debian.org/kernel/crda.git Vcs-Browser: http://git.debian.org/?p=kernel/crda.git Homepage: http://wireless.kernel.org/en/developers/Regulatory/#CRDA Package: crda Architecture: linux-any Multi-Arch: foreign Depends: ${shlibs:Depends}, ${misc:Depends}, wireless-regdb Recommends: iw Breaks: wireless-crda (<< 1.15), wireless-regdb (= 2011.04.28-1ubuntu1), wireless-regdb (= 2011.04.28-1ubuntu2) Replaces: wireless-crda (<< 1.15), wireless-regdb (= 2011.04.28-1ubuntu1), wireless-regdb (= 2011.04.28-1ubuntu2) Description: wireless Central Regulatory Domain Agent This package provides a Central Regulatory Domain Agent (CRDA) to be used by the Linux kernel cf80211 wireless subsystem to query and apply the regulatory domain settings wireless devices may operate within for a given location. . CRDA queries operational frequency regulations stored within the regulatory database provided by the wireless-regdb package. debian/rules0000755000000000000000000000112311707553673010261 0ustar #!/usr/bin/make -f export CFLAGS = -O$(if $(findstring noopt,$(DEB_BUILD_OPTIONS)),0,2) export REG_BIN = /lib/crda/regulatory.bin export USE_OPENSSL = 1 export RUNTIME_PUBKEY_DIR = /lib/crda/pubkeys export RUNTIME_PUBKEY_ONLY = 1 export V = 1 #export DH_VERBOSE = 1 %: dh ${@} override_dh_auto_build: dh_auto_build -- all_noverify override_dh_install: dh_install install -D -o 0 -g 0 -m 755 debian/setregdomain \ debian/crda/lib/crda/setregdomain mkdir -m 755 debian/crda/$(RUNTIME_PUBKEY_DIR) install -m 644 pubkeys/*.pem debian/pubkeys/*.pem \ debian/crda/$(RUNTIME_PUBKEY_DIR)/ debian/compat0000644000000000000000000000000211707553673010402 0ustar 8 debian/gbp.conf0000644000000000000000000000004511707553673010622 0ustar [git-buildpackage] compression=bzip2 debian/pubkeys/0000755000000000000000000000000011707574743010667 5ustar debian/pubkeys/benh@debian.org.key.pub.pem0000644000000000000000000000070311707553673015712 0ustar -----BEGIN PUBLIC KEY----- MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAneF3oCSg1XllOgeQyfal ph+EHCMHS0+lA8YP91TVi355gQDS6T30l/6EzVW9yY8hV4gGOZBmQSZ5LMo/lYcB ES8vsOELQ/xfL09nBNtNt3JN0cV2c02RabBxFzbqqwo6zZWbdhuOIRePxQK/JMfA QLE7xIB8caVR3Pc6WH+xB4GKENH2kxdx4PpReRXU14+tvW844SZ9vPA+gIm07I5p kNuXivAjI4OCO2qxrOvnmXQqNY6pZP1GnujlSGExbub8GRhUwxtP1gBEhxw3Rer1 ycsPDFXsz2rCRSYjojFSTe4hff1YcsIoxY6p0O4Bdwil8CIrR3krz5pGtY/9ZKK1 7QIDAQAB -----END PUBLIC KEY-----