Age | Commit message (Collapse) | Author | Files | Lines |
|
crda:
have choice for python(abi) needed by python-M2Crypto: python3-base python
have choice for python(abi) needed by python-typing: python3-base python
Change-Id: Ic342a28d45710b10fab2cae26765cddd27bfd9f7
|
|
- libnl2: Use pkgconfig
- python-typing: Remove. It is added as 'Requires' package in python-M2Crypto
Change-Id: Ide2e823b7384155ce373760cc208e3594395f218
|
|
Change-Id: If0863f74b2ec879d39ce58252c53a68f9459b30d
|
|
Change-Id: I8cef8ec05ae058087bf094ca6bd1855425197152
|
|
Change-Id: I3a1b59b5c4919a6b22aacf2746a34dac4884154e
|
|
Change-Id: I3c3a171b83ec9c8d7281feda7c6d4d382c99a5d0
Signed-off-by: Taesub Kim <taesub.kim@samsung.com>
|
|
|
|
|
|
|
|
This fixes these compile warnings:
make -j5 -l4 UDEV_RULE_DIR=/lib/udev/rules.d
REG_BIN=/usr/lib64/crda/regulatory.bin USE_OPENSSL=1
CC=x86_64-pc-linux-gnu-gcc all_noverify V=1
x86_64-pc-linux-gnu-gcc -c -Os -pipe -march=native
-frecord-gcc-switches -ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -o crda.o crda.c
x86_64-pc-linux-gnu-gcc -c -Os -pipe -march=native
-frecord-gcc-switches -ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -o intersect.o
intersect.c
./utils/key2pub.py --ssl pubkeys/linville.key.pub.pem keys-ssl.c
x86_64-pc-linux-gnu-gcc -c -Os -pipe -march=native
-frecord-gcc-switches -ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -o
print-regdom.o print-regdom.c
x86_64-pc-linux-gnu-gcc -c -Os -pipe -march=native
-frecord-gcc-switches -ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -o regdbdump.o
regdbdump.c
x86_64-pc-linux-gnu-gcc -c -Os -pipe -march=native
-frecord-gcc-switches -ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -o reglib.o
reglib.c
reglib.c: In function ‘country2rd’:
reglib.c:213:2: warning: implicit declaration of function ‘memset’
[-Wimplicit-function-declaration]
reglib.c:213:2: warning: incompatible implicit declaration of built-in
function ‘memset’ [enabled by default]
reglib.c: In function ‘reglib_get_rd_alpha2’:
reglib.c:344:3: warning: implicit declaration of function ‘memcmp’
[-Wimplicit-function-declaration]
x86_64-pc-linux-gnu-gcc -Os -pipe -march=native -frecord-gcc-switches
-ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -Wl,-O1
-Wl,--as-needed -Wl,--hash-style=gnu -o crda reglib.o crda.o `pkg-config
--libs openssl` -lnl-genl-3 -lnl-3 `pkg-config --libs libnl-3.0`
x86_64-pc-linux-gnu-gcc -Os -pipe -march=native -frecord-gcc-switches
-ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -Wl,-O1
-Wl,--as-needed -Wl,--hash-style=gnu -o intersect reglib.o intersect.o
print-regdom.o `pkg-config --libs openssl`
x86_64-pc-linux-gnu-gcc -Os -pipe -march=native -frecord-gcc-switches
-ggdb -Wall -g -DUSE_OPENSSL
-DPUBKEY_DIR=\"/etc/wireless-regdb/pubkeys\" `pkg-config --cflags
openssl` -DCONFIG_LIBNL30 `pkg-config --cflags libnl-3.0` -Wl,-O1
-Wl,--as-needed -Wl,--hash-style=gnu -o regdbdump reglib.o regdbdump.o
print-regdom.o `pkg-config --libs openssl`
Reported-by: Richard Farina <sidhayn@gmail.com>
Signed-off-by: Luis R. Rodriguez <mcgrof@do-not-panic.com>
|
|
reglib_get_country_idx() --> reglib_get_rd_alpha2()
reglib_get_country_alpha2() --> reglib_get_rd_alpha2()
This reflects better what we provide back out.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
The only other remaining user of regdb.h is regdbdump tool
but as I see it this utility can exist in either a reglib
library, or on each OS for its own specific adaptation of
the reglib code. For now we just make regdbump use the local
copy of nl80211.h. Later the reglib library can have its own
print / dump utility if we deem it necessary.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
Remove unused headers now that we have an object
(soon to be library) using what it has to separately.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
This removes all file specific operations over to the
reglib. This also required converting the processing of the
regulatory domain from the mmap'd rules to the standard
ieee80211_regdomain data structure.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
This will be used later once crda.c starts using the
ieee80211_regdomain data structure passed on from reglib
instead of using the mmap()'d regulatory file directly.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
This will be used by CRDA to find the alpha2.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
This was never done. Do this at the end for now but soon
this will be changed in preference for the file opening
only to be done by crda for checking which file to use
to pass on to reglib for usage.
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
To allow for a simple library on reglib.c we want to enable
an iterator over the regulatory database that does not have
to lock the file, or pass references to the file. We instead
add an iterator reglib_get_country_idx() which will use a
new reglib_get_country_idx(), that does an O(n) search for
each new regulatory domain it needs to read.
The trade off here is to allow for a simple reglib.c implementation
at the cost that upon each iteration reglib_get_country_idx()
we will will be opening the regdb, and verifying the db signature.
Given that the only user of this iterator is regdbdump though and
that this is used for debugging for now this is trade off I am
willing to live with.
Systems that want to use the regdb as a database for fine tuning
radio parameters dynamically and reading this file very *often*
(seconds, minutes, who knows what the future holds) may want to
consider a slight optimization of exporting the direct mmap()
through the library but we are I think light years away from that.
Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
|
|
Start cleaning the way we deal with reglib.c as the goal
is to make that stuff a library to be shared first in
userspace with the regulatory simulator [0]. We start
off by moving country2rd() and its helper over to
reglib.c.
[0] git://github.com/mcgrof/regsim.git
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
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 <s.l-h@gmx.de>
Signed-off-by: Luis R. Rodriguez <mcgrof@frijolero.org>
|
|
Given that we may need to make a library out of some
routines here to share with the regulatory simulator.
Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
|
|
wireless-regdb now has support for a DFS master region
for each country. We must read this from the file and
send it as an NL80211_ATTR_DFS_REGION attribute.
We add a "creqs" value for the country structure but only
use the first two bits as that is all we need right now.
Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
|
|
The wireless-regdb only accounts for two bytes for
the country code but CRDA defined the alpha2 to be
as a string of length 2, and so does the nl80211 attribute
policy:
[NL80211_ATTR_REG_ALPHA2] = { .type = NLA_STRING, .len = 2 },
The meaning of a string is it'll be null terminated, so if you
do not add the null termination a country without the null termination
will not match up with the nl80211 attribute policy.
This has no impact for us unless we want to use the next available
pad byte on the wireless-regdb. This fixes CRDA by using a local copy
of the regdb's alpha2 that is properly null terminated and sending it.
The implications of this change is that new wirelesss-regdb's that
make use of the next pad byte for a country will get that country
ignored for regulatory hints sent to the kernel. At this point we
don't yet know what the next byte will be used for though so this
has no impact. The second pad byte is being used for DFS and that
is not impacted by this nor is this change required for it.
Distributions should upgrade though in case we ever do decide to use
this last precious country byte. I've tested that this indeed fixes
the bogus issue I saw when instead of using the second pad byte we
use the first pad byte. Thanks to Johannes for spotting the issue.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
|
|
Signed-off-by: Luis R. Rodriguez <mcgrof@qca.qualcomm.com>
|
|
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
This patch allows crda to load and use additional keys from a
pre-configured location for the database signature verification. This
provides a convenient way for distro maintainers and card manufacturers to
supply a custom regulatory database along with their public keys, without
the need to recompile crda.
Implemented for USE_OPENSSL=1 case only because libgcrypt lacks PEM parser.
Default location for public keys in PEM format is
/etc/wireless-regdb/pubkeys and can be changed by specifying
RUNTIME_PUBKEY_DIR at the make command line.
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
|
|
BugLink: http://bugs.launchpad.net/bugs/340995
SBINDIR already has a trailing '/', so its not needed
in the udev rule.
Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
|
|
On Thu, 2009-08-06 at 09:56 -0700, Luis R. Rodriguez wrote:
> ACK, is it possible to make it simpler?
OK, here's my take.
We only need a native compiler to verify regulatory.bin. I believe it's
orthogonal to building CRDA.
For someone doing a cross-compilation, it makes no sense to verify the
installed regulatory.bin. Thus, the verification should be optional.
But the compilation of regdbdump shouldn't be. Firstly, it's installed
by "make install". Secondly, somebody may want to verify regulatory.bin
on the target system.
Here's the patch:
crda: make it possible to disable verification
Signed-off-by: Pavel Roskin <proski@gnu.org>
|
|
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
|
|
openssl uses unsigned longs -- which are 8 bytes on 64-bit
platforms, not 4, so the python code needs to account for
that... how stupid!
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
|
|
it seems openssl caches some things in there and subsequent
uses of the same key struct fail or something -- since this
fixes it I'm not bothering trying to figure out what's wrong
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
|
|
Distributions which need a custom pubkey dir can just
specify it upon build time.
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
/usr/lib/crda
As crda is typically installed in /sbin it might be worth to install
regulatory.bin into /lib/crda instead of /usr/lib/crda. Hence, extend
crda to try both paths for loading the database.
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
|
|
You supply the user with a chance to specify SBINDIR during make
install, yet forgot to use it in one place at the install target. I
attached a patch against trunk for crda.git which fixes that.
|
|
Upstream has renamed nl_handle to nl_sock. Update crda to the new names
and add #define for libnl-1.1.
Signed-off-by: Pat Erley <pat-lkml@erley.org>
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Otherwise, the error messase would be very confusing.
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
For --as-needed to work (and for traditional ld too) the libraries should
always be passed _after_ the object files, move them so that they are
picked up properly.
Also rename LIBS to NLLIBS to avoid confusion between LIBS/LDLIBS.
Signed-off-by: Diego E. 'Flameeyes' Pettenò <flameeyes@gmail.com>
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
This one uses cdbs to make debian/rules smaller.
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|
|
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
|