aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/src/crypto/zinc/selftest (follow)
Commit message (Collapse)AuthorAgeFilesLines
* crypto: use BIT(i) & bitmap instead of (bitmap >> i) & 1Jason A. Donenfeld2018-10-071-2/+2
| | | | | | | | | | | Pros: clearer if you're not familiar with the shift idiom, uses kernel macro. Cons: doesn't work any more if the lvalue ever ceases to be a bool. Neutral: generates the same machine code. Suggested-by: Sultan Alsawaf <sultanxda@gmail.com>
* crypto: disable broken implementations in selftestsJason A. Donenfeld2018-10-071-9/+8
|
* crypto: test all SIMD combinationsJason A. Donenfeld2018-10-066-22/+49
|
* global: rename include'd C files to be .cJason A. Donenfeld2018-10-065-5/+5
| | | | | | | | | This is done by 259 other files in the kernel tree: linux $ rg '#include.*\.c' -l | wc -l 259 Suggested-by: Sultan Alsawaf <sultanxda@gmail.com>
* simd: introduce useful disabling macroJason A. Donenfeld2018-10-032-3/+2
|
* chacha20: test multiple page span in selftestJason A. Donenfeld2018-10-021-3/+26
|
* chacha20: break out of zero loops in selftestJason A. Donenfeld2018-10-021-0/+5
|
* crypto: rename DEBUG to SELFTESTJason A. Donenfeld2018-09-255-50/+49
| | | | | Also we make selftest errors of type err, so that they're obvious in dmesg.
* curve25519: show all failures in test caseJason A. Donenfeld2018-09-251-2/+0
|
* chacha20: add bounds checking to selftestsJason A. Donenfeld2018-09-251-1/+45
|
* crypto: make constant naming scheme consistentJason A. Donenfeld2018-09-253-21/+21
|
* hchacha20: keep in native endian in wordsJason A. Donenfeld2018-09-251-3/+5
|
* global: reduce stack frame sizeJason A. Donenfeld2018-09-232-25/+35
| | | | This brings it under 1280 on 64-bit and under 1024 on 32-bit systems.
* chacha20: add chunked selftest and test sliding alignments and hchacha20Jason A. Donenfeld2018-09-232-1160/+2467
| | | | | This ensures we're properly updating state[12] and that we're handling all unaligned acceses (in the jump tables for MIPS).
* global: put SPDX identifier on its own lineJason A. Donenfeld2018-09-205-10/+10
| | | | | The kernel has very specific rules correlating file type with comment type, and also SPDX identifiers can't be merged with other comments.
* crypto: do not waste space on selftest itemsJason A. Donenfeld2018-09-203-9458/+10993
| | | | | | This unfortunately means we have to define symbols, since we want them in __initconst, but it's better than the other two options (no initconst or wasting space for fixed size buffers).
* crypto: explicitly dual licenseJason A. Donenfeld2018-09-205-5/+5
| | | | Suggested-by: Thomas Gleixner <tglx@linutronix.de>
* poly1305: account for simd being toggled off midwayJason A. Donenfeld2018-09-201-0/+17
| | | | | | This is a very rare occurance, but we should account for it, so that the calculations aren't wrong. Here we convert from base 2^26 back to base 2^64.
* chacha20: add independent self testJason A. Donenfeld2018-09-181-0/+1182
| | | | | This was already tested from the chacha20poly1305 test, but it's useful to be able to test this in isolation too.
* chacha20poly1305: add __init to selftest helper functionsJason A. Donenfeld2018-09-181-3/+3
|
* crypto: turn Zinc into individual modulesJason A. Donenfeld2018-09-184-4/+4
|
* crypto: pass simd by referenceJason A. Donenfeld2018-09-172-26/+29
|
* poly1305: do not require simd context for archJason A. Donenfeld2018-09-172-5/+3
|
* crypto: make MITJason A. Donenfeld2018-09-164-4/+4
|
* poly1305: rename finish to finalJason A. Donenfeld2018-09-112-3/+3
|
* crypto: do not use compound literals in selftestsJason A. Donenfeld2018-09-112-7704/+7710
| | | | | | | gcc can't apply section attributes to compound literals, so we can't mark the actual data as __initconst. We thus waste space instead, but this shouldn't matter much, since it's cleared after init anyway, and because this is only for debugging.
* poly1305: rewrite self tests from scratchJason A. Donenfeld2018-09-081-1529/+831
| | | | This removes the old cruft and makes things a bit more idiomatic.
* crypto: use CRYPTOGAMS licenseJason A. Donenfeld2018-09-061-1/+1
|
* crypto: import zincJason A. Donenfeld2018-09-034-0/+12836