commit crda for openSUSE:Factory
![](https://seccdn.libravatar.org/avatar/e2145bc5cf53dda95c308a3c75e8fef3.jpg?s=120&d=mm&r=g)
Hello community,
here is the log from the commit of package crda for openSUSE:Factory
checked in at Thu Jul 30 14:31:49 CEST 2009.
--------
--- crda/crda.changes 2009-03-02 10:59:41.000000000 +0100
+++ /mounts/work_src_done/STABLE/crda/crda.changes 2009-07-28 21:42:30.000000000 +0200
@@ -1,0 +2,6 @@
+Tue Jul 28 21:29:47 CEST 2009 - aj@suse.de
+
+- Update to crda 1.1.0:
+ * make openssl keys 64-bit safe
+
+-------------------------------------------------------------------
calling whatdependson for head-i586
Old:
----
crda-1.0.1.tar.bz2
New:
----
crda-1.1.0.tar.bz2
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ crda.spec ++++++
--- /var/tmp/diff_new_pack.knBQYU/_old 2009-07-30 14:28:42.000000000 +0200
+++ /var/tmp/diff_new_pack.knBQYU/_new 2009-07-30 14:28:42.000000000 +0200
@@ -1,5 +1,5 @@
#
-# spec file for package crda (Version 1.0.1)
+# spec file for package crda (Version 1.1.0)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
@@ -21,10 +21,10 @@
Name: crda
Summary: 802.11 central regulatory domain agent
-Version: 1.0.1
-Release: 3
+Version: 1.1.0
+Release: 1
Group: Hardware/Wifi
-License: BSD 3-Clause
+License: BSD 3-clause (or similar)
Source: %{name}-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: libgcrypt-devel libnl-devel pkg-config python python-m2crypto udev wireless-regdb
++++++ crda-1.0.1.tar.bz2 -> crda-1.1.0.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crda-1.0.1/Makefile new/crda-1.1.0/Makefile
--- old/crda-1.0.1/Makefile 2009-01-24 22:39:26.000000000 +0100
+++ new/crda-1.1.0/Makefile 2009-04-17 23:49:45.000000000 +0200
@@ -16,8 +16,11 @@
# a different location.
UDEV_RULE_DIR?=/lib/udev/rules.d/
-# Used locally to retrieve all pubkeys during build time
-PUBKEY_DIR=pubkeys
+# If your distribution requires a custom pubkeys dir
+# you must update this variable to reflect where the
+# keys are put when building. For example you can run
+# with make PUBKEY_DIR=/usr/lib/crda/pubkeys
+PUBKEY_DIR?=pubkeys
CFLAGS += -Wall -g
@@ -52,6 +55,10 @@
NLLIBNAME = libnl-2.0
endif
+ifeq ($(NLLIBNAME),)
+$(error Cannot find development files for any supported version of libnl)
+endif
+
NLLIBS += `pkg-config --libs $(NLLIBNAME)`
CFLAGS += `pkg-config --cflags $(NLLIBNAME)`
@@ -77,6 +84,7 @@
keys-%.c: utils/key2pub.py $(wildcard $(PUBKEY_DIR)/*.pem)
$(NQ) ' GEN ' $@
+ $(NQ) ' Trusted pubkeys:' $(wildcard $(PUBKEY_DIR)/*.pem)
$(Q)./utils/key2pub.py --$* $(wildcard $(PUBKEY_DIR)/*.pem) $@
%.o: %.c regdb.h
@@ -105,7 +113,7 @@
install: crda crda.8.gz regdbdump.8.gz
$(NQ) ' INSTALL crda'
- $(Q)$(MKDIR) $(DESTDIR)/sbin
+ $(Q)$(MKDIR) $(DESTDIR)/$(SBINDIR)
$(Q)$(INSTALL) -m 755 -t $(DESTDIR)/$(SBINDIR) crda
$(NQ) ' INSTALL regdbdump'
$(Q)$(INSTALL) -m 755 -t $(DESTDIR)/$(SBINDIR) regdbdump
@@ -114,7 +122,8 @@
@# This removes the old rule you may have, we were not
@# putting it in the right place.
$(Q)rm -f $(DESTDIR)/etc/udev/rules.d/regulatory.rules
- $(Q)ln -sf regulatory.rules udev/$(UDEV_LEVEL)regulatory.rules
+ $(Q)sed 's:$$(SBINDIR):$(SBINDIR):' udev/regulatory.rules > udev/regulatory.rules.parsed
+ $(Q)ln -sf regulatory.rules.parsed udev/$(UDEV_LEVEL)regulatory.rules
$(Q)$(INSTALL) -m 644 -t \
$(DESTDIR)/$(UDEV_RULE_DIR)/ \
udev/$(UDEV_LEVEL)regulatory.rules
@@ -126,4 +135,4 @@
clean:
$(Q)rm -f crda regdbdump intersect *.o *~ *.pyc keys-*.c *.gz \
- udev/$(UDEV_LEVEL)regulatory.rules
+ udev/$(UDEV_LEVEL)regulatory.rules udev/regulatory.rules.parsed
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crda-1.0.1/crda.c new/crda-1.1.0/crda.c
--- old/crda-1.0.1/crda.c 2009-01-24 22:39:26.000000000 +0100
+++ new/crda-1.1.0/crda.c 2009-04-17 23:49:45.000000000 +0200
@@ -43,10 +43,11 @@
}
#define genl_ctrl_alloc_cache __genl_ctrl_alloc_cache
+#define nl_sock nl_handle
#endif /* CONFIG_LIBNL20 */
struct nl80211_state {
- struct nl_handle *nl_handle;
+ struct nl_sock *nl_sock;
struct nl_cache *nl_cache;
struct genl_family *nl80211;
};
@@ -55,22 +56,22 @@
{
int err;
- state->nl_handle = nl_socket_alloc();
- if (!state->nl_handle) {
- fprintf(stderr, "Failed to allocate netlink handle.\n");
+ state->nl_sock = nl_socket_alloc();
+ if (!state->nl_sock) {
+ fprintf(stderr, "Failed to allocate netlink sock.\n");
return -ENOMEM;
}
- if (genl_connect(state->nl_handle)) {
+ if (genl_connect(state->nl_sock)) {
fprintf(stderr, "Failed to connect to generic netlink.\n");
err = -ENOLINK;
- goto out_handle_destroy;
+ goto out_sock_destroy;
}
- if (genl_ctrl_alloc_cache(state->nl_handle, &state->nl_cache)) {
+ if (genl_ctrl_alloc_cache(state->nl_sock, &state->nl_cache)) {
fprintf(stderr, "Failed to allocate generic netlink cache.\n");
err = -ENOMEM;
- goto out_handle_destroy;
+ goto out_sock_destroy;
}
state->nl80211 = genl_ctrl_search_by_name(state->nl_cache, "nl80211");
@@ -84,8 +85,8 @@
out_cache_free:
nl_cache_free(state->nl_cache);
- out_handle_destroy:
- nl_socket_free(state->nl_handle);
+ out_sock_destroy:
+ nl_socket_free(state->nl_sock);
return err;
}
@@ -93,7 +94,7 @@
{
genl_family_put(state->nl80211);
nl_cache_free(state->nl_cache);
- nl_socket_free(state->nl_handle);
+ nl_socket_free(state->nl_sock);
}
static int reg_handler(struct nl_msg __attribute__((unused)) *msg,
@@ -142,7 +143,7 @@
int main(int argc, char **argv)
{
- int fd;
+ int fd = -1;
struct stat stat;
__u8 *db;
struct regdb_file_header *header;
@@ -161,7 +162,13 @@
struct nlattr *nl_reg_rules;
int num_rules;
- const char regdb[] = "/usr/lib/crda/regulatory.bin";
+ const char *regdb_paths[] = {
+ "/usr/local/lib/crda/regulatory.bin", /* Users/preloads can override */
+ "/usr/lib/crda/regulatory.bin", /* General distribution package usage */
+ "/lib/crda/regulatory.bin", /* alternative for distributions */
+ NULL
+ };
+ const char **regdb = regdb_paths;
if (argc != 1) {
fprintf(stderr, "Usage: %s\n", argv[0]);
@@ -182,7 +189,12 @@
memcpy(alpha2, env_country, 2);
- fd = open(regdb, O_RDONLY);
+ while (*regdb != NULL) {
+ fd = open(*regdb, O_RDONLY);
+ if (fd >= 0)
+ break;
+ regdb++;
+ }
if (fd < 0) {
perror("failed to open db file");
return -ENOENT;
@@ -294,7 +306,7 @@
if (!cb)
goto cb_out;
- r = nl_send_auto_complete(nlstate.nl_handle, msg);
+ r = nl_send_auto_complete(nlstate.nl_sock, msg);
if (r < 0) {
fprintf(stderr, "Failed to send regulatory request: %d\n", r);
@@ -306,7 +318,7 @@
nl_cb_err(cb, NL_CB_CUSTOM, error_handler, NULL);
if (!finished) {
- r = nl_wait_for_ack(nlstate.nl_handle);
+ r = nl_wait_for_ack(nlstate.nl_sock);
if (r < 0) {
fprintf(stderr, "Failed to set regulatory domain: "
"%d\n", r);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crda-1.0.1/crda.spec new/crda-1.1.0/crda.spec
--- old/crda-1.0.1/crda.spec 2009-01-24 22:39:26.000000000 +0100
+++ new/crda-1.1.0/crda.spec 2009-04-17 23:49:45.000000000 +0200
@@ -1,6 +1,6 @@
Summary: Linux central regulatory domain agent
Name: crda
-Version: 1.0.0
+Version: 1.0.1
Release: 1
License: ISC
Group: System Enviroment/Base
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/crda-1.0.1/debian-example/changelog new/crda-1.1.0/debian-example/changelog
--- old/crda-1.0.1/debian-example/changelog 2009-01-24 22:39:26.000000000 +0100
+++ new/crda-1.1.0/debian-example/changelog 2009-04-17 23:49:45.000000000 +0200
@@ -1,3 +1,9 @@
+crda (1.0.1-1) unstable; urgency=low
+
+ * Compiles nicely on # CPUs > 1
+
+ -- Luis R. Rodriguez
participants (1)
-
root@Hilbert.suse.de