Age | Commit message (Collapse) | Author | Files | Lines |
|
Signed-off-by: Aaron Grothe <ajgrothe@yahoo.com>
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: David S. Miller <davem@redhat.com>
|
|
This code is a rework of the original Gladman AES code, and does not
include any supposed BSD licensed work by Jari Ruusu.
Linus converted the Intel asm to Gas format, and made some minor
alterations.
Fruhwirth's glue module has also been retained, although I rebased the
table generation and key scheduling back to Gladman's code. I've tested
this code with some standard FIPS test vectors, and large FTP transfers
over IPSec (both locally and over the wire to a system running the
generic AES implementation).
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
|
|
This patch reverts the i586 AES module. A new one should be ready soon.
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
|
|
Below is an updated version of patch from Fruhwirth which integrates the
Gladman AES code into the crypto API.
I've tried to ensure that this is done as simply as possible: the user
gets the asm version by default if it's suitable.
I've also now added the alternate GPL licensing provided by Brian Gladman,
and licensed the code as GPL.
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: David S. Miller <davem@redhat.com>
|
|
The stack allocation in crypt() is bogus as whether tmp_src/tmp_dst
is used is determined by factors unrelated to nbytes and
src->length/dst->length.
Since the condition for whether tmp_src/tmp_dst are used is very
complex, let's allocate them always instead of guessing.
This fixes a number of weird crashes including those AES crashes
that people have been seeing with the 2.4 backport + ipt_conntrack.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: David S. Miller <davem@redhat.com>
|
|
|
|
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: David S. Miller <davem@redhat.com>
|
|
The following is a patch against 2.6.7 (should apply cleanly to 2.6.5 or
above). It implements the Tiny Encryption Algorithm (TEA) and the
Xtended TEA (XTEA) algorithms. TEA goes back to 1994 and is a good
algorithm espically for memory constrained systems. It is similar in
concept to the IDEA crypto. It does NOT have any patent restrictions
and has been put in the public domain by Wheeler and Needham. Tea is used
in quite a few products such as filesafe and even Microsoft's Xbox.
Signed-off-by: Aaron Grothe <ajgrothe@yahoo.com>
Signed-off-by: James Morris <jmorris@redhat.com>
Signed-off-by: David S. Miller <davem@redhat.com>
|
|
Below is the patch, against 2.6.7-rc2, to fix crypto/digest.c to do
multiple kmap()/kunmap() for scatterlist entries which have a size
greater than a single page, originally found and fixed by
N.C.Krishna Murthy <krmurthy@cisco.com>.
Signed-off-by: Clay Haapala <chaapala@cisco.com>
Signed-off-by: David S. Miller <davem@redhat.com>
|
|
- After calling scatterwalk_copychunks walk_in might point to the next
page which will break scatterwalk_samebuf (in this case src_p should
point to tmp_src anyway and scatterwalk_samembuf returns 0).
- scatterwalk_samebuf should also check for equal offsets inside the page
(just bad for performance in some cases).
|
|
|
|
|
|
|
|
|
|
From: Martin Schwidefsky <schwidefsky@de.ibm.com>
Add support for z990 crypto instructions to in-kernel crypto api.
|
|
|
|
|
|
From Jouni Malinen <jkmaline@cc.hut.fi>
Added Michael MIC keyed digest for TKIP (IEEE 802.11i/WPA). This algorithm
is quite weak due to the requirements for compatibility with old legacy
wireless LAN hardware that does not have much CPU power. Consequently, this
should not really be used with anything else than TKIP.
Michael MIC is calculated over the payload of the IEEE 802.11 header which
makes it easier to add TKIP support for old wireless LAN cards. An additional
authenticated data area is used (but not send separately) to authenticate
source and destination addresses.
|
|
From Jouni Malinen <jkmaline@cc.hut.fi>
Added support for using keyed digest with an optional dit_setkey handler.
This does not change the behavior of the existing digest algorithms, but
allows new ones to add setkey handler that can be used to initialize the
algorithm with a key or seed. setkey is to be called after init, but before
any of the update call(s).
|
|
|
|
Declarations come before statements, please.
Current gcc warns about this too, bless them:
crypto/arc4.c: In function `arc4_crypt':
crypto/arc4.c:65: warning: ISO C90 forbids mixed declarations and code
|
|
|
|
From: Christophe Saout <christophe@saout.de>
This patch fixes the bug where in-place encryption was not detected when
the same highmem pages is mapped twice to different virtual addresses.
This adds a parameter to xxx_process to indicate whether this is an
in-place encryption and moves the responsability to the caller using a
helper function scatterwalk.h.
|
|
From: Christophe Saout <christophe@saout.de>
I've cleaned up the latest patches and adjusted the header files.
This patch moves the scatterwalk functions from cipher.c to
scatterwalk.c and adds a header file.
|
|
|
|
Also happens to work around a GCC bug.
|
|
Jakub points out that having an automatic array is not only
bad for performance (and stack usage), gcc has also historically
had lots of bugs here, and gcc-3.2.3 seems to miscompile it
otherwise.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Similar to the patch Brian Gerst sent for CRC32, this patch changes
ZLIB_{IN,DE}FLATE to be select'ed.
The dependencies are much better maintainable that way.
|
|
|
|
try_then_request_module() does what crypto/autoload.c is doing, so
replace it. Fix try_then_request_module(), too (thanks James).
|
|
|
|
|
|
|
|
into home.osdl.org:/home/torvalds/v2.5/linux
|
|
Based upon patches from Yoshfuji Hideaki <yoshfuji@linux-ipv6.org>
|
|
|
|
|
|
From: Leann Ogasawara <ogasawara@osdl.org>
Uninitialize static variables initialized to 0 so they are pushed to the
.bss instead of .data.
|
|
|
|
|
|
|
|
|
|
This is what a lot of the callers really wanted.
|
|
|
|
|
|
into nuts.ninka.net:/home/davem/src/BK/net-2.5
|
|
|
|
|
|
1) Every arch implemented local_bh_foo identically, move to
linux/interrupt.h
2) Kill all asm/softirq.h references
3) Kill asm/softirq.h itself
4) Move local_bh_disable() out of line to kernel/softirq.c
5) Add BUG check on irqs_disabled() to local_bh_disable()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
into kernel.bkbits.net:/home/davem/net-2.5
|
|
One of the goals of the whole new modversions implementation:
export-objs is gone for good!
|
|
- Merge scatterwalk patch from Adam J. Richter <adam@yggdrasil.com>
API change: cipher methods now take in/out scatterlists and nbytes
params.
- Merge gss_krb5_crypto update from Adam J. Richter <adam@yggdrasil.com>
- Add KM_SOFTIRQn (instead of KM_CRYPTO_IN etc).
- Add asm/kmap_types.h to crypto/internal.h
- Update cipher.c credits.
- Update cipher.c documentation.
|
|
|
|
|
|
- Merged SHA-384 and SHA-512 code from Kyle McMartin
<kyle@gondolin.debian.net>
- Added test vectors.
- Documentation and credits updates.
|
|
|
|
|
|
|
|
- Merged AES code from Adam J. Richter <adam@yggdrasil.com>
- Add kconfig help and test vector code from
Martin Clausen <martin@ostenfeld.dk>
- Minor cleanups: removed EXPORT_NO_SYMBOLS (not needed for 2.5),
removed debugging code etc.
- Documentation updates.
|
|
|
|
I missed one hunk when splitting the patch for removing
try_inc_mod_count().
|
|
A second start at removing them from kernel/*.c and fs/*.c.
Note that module_put is fine for a NULL argument.
|
|
Makefiles no longer need to include Rules.make, which is currently an
empty file. This patch removes it from the remaining Makefiles, and
removes the empty Rules.make file.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Fixes crypto so it compiles with !CONFIG_MODULES, and cleans up two
other cases which did #ifdef CONFIG_MODULES.
|
|
- Fixed min keysize bug for Blowfish (it is 32, not 64).
- Documentation updates.
|
|
|
|
|
|
|
|
- Bugfix in sha1 copyright
- Add support for SHA256, test vectors and HMAC test vectors
- Remove obsolete atomic messages.
|
|
|
|
|
|
|
|
into nuts.ninka.net:/home/davem/src/BK/net-2.5
|
|
|
|
- make crypto_cipher_flags() return u32 (this means it will return
the actual flags reliably, instead of being just a boolean op).
- simplify error path in crypto_init_flags().
|
|
into penguin.transmeta.com:/home/penguin/torvalds/repositories/kernel/linux
|
|
|
|
- Changed unsigned to unsigned int in algos.
- Consistent use of u32 for flags throughout api.
- Use of unsigned int rather than int for counting things which must
be positive, also replaced size_ts to keep code simpler and lessen
bloat on some archs.
- got rid of some unneeded returns.
- const correctness.
|
|
|
|
|
|
This adds the remaining config files.
|
|
|
|
|
|
|
|
|
|
- Removed local_bh_disable() from kmap wrapper, not needed now with
two atomic kmaps.
- Nuked atomic flag, use in_softirq() instead.
- Converted crypto_kmap() and crypto_yield() to check in_softirq().
- Check CRYPTO_MAX_CIPHER_BLOCK_SIZE during alg init.
- Try to initialize as much at compile time as possible
(feedback from Christoph Hellwig).
- Clean up list handling a bit (feedback from Christoph Hellwig).
|
|
|
|
- API change: implemented simplest version of algorithm lookup
by name (feedback from Rusty Russell and Herbert Valerio Riedel).
- Now need to add the following line to to /etc/modules.conf for
dynamic module loading:
alias des3_ede des
|
|
|
|
|
|
- added back USAGI copyright for HMAC (lost earlier during some
refactoring).
- bugfix: make sure tfm pointer is set to NULL during post allocation
failure path in crypto_alloc_tfm()
|
|
- try_inc_mod_count() already does what crypto_alg_get() was trying to do.
(feedback from Andrew Morton).
- Moved the BUG_ON() in crypto_unregister_alg() further up, no need to
bother iterating over the list.
- Always use kmap_atomic (feedback from Andrew Morton). Implemented two
atomic kmaps, KM_USER for user context and KM_SOFTIRQ for softirq
context.
- Fixup KM_CRYPTO_ placement so Dave does not go crazy.
|
|
|
|
|
|
- s/__u/u/
- s/char/u8/
- Fixed bug in cipher.c, page remapped was off by one block
|
|
|
|
- Add missing includes of asm/byteorder.h
- Fix sha1.c compiler crash with egcs-2.92.x
- Use correct printf format for size_t types.
|
|
|