1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2024-12-29 04:50:03 +01:00
Commit Graph

22 Commits

Author SHA1 Message Date
Gaëtan Harter
fa33eacd1f
crypto/ccm: fix _fits_in_nbytes function
Function is broken with num_bytes >= 4.

Could happen when storing input_len with len_encoding >= 4.
It can take values from 2 to 8, so make it work for cases it would overflow.
2018-05-07 15:08:00 +02:00
Gaëtan Harter
a47e5e427e
tests/ccm: add test for input_len check 2018-05-07 15:08:00 +02:00
Gaëtan Harter
30202f9de7 tests/ccm: check output buffer size
Add static test to verify output buffer is big enough for testing.
2018-01-04 18:01:58 +01:00
Gaëtan Harter
a83a1a80e5 tests/ccm: support input/adata bigger than 256
Fix data types to have bigger sizes.
The 'data' buffer size will still need to be increased when adding bigger tests.
2018-01-03 12:02:29 +01:00
Gaëtan Harter
e74b0ff33d tests/ccm: set 'len_encoding' from 'nonce_len'
Configure len_encoding in test depending on nonce_len.
Prepare for tests with nonce_len != 13.
2018-01-03 12:02:28 +01:00
Gaëtan Harter
b5c1855d7e tests/ccm: make 'mac_length' configurable in test
Preparation to add tests with different mac_length than 8.
2018-01-03 12:02:20 +01:00
Gaëtan Harter
fc3efbd0ee tests/ccm: add macro to simplify test call 2018-01-03 12:02:16 +01:00
Gaëtan Harter
5f6dc57d09 tests/ccm: fixup indentation 2018-01-03 12:01:57 +01:00
Emmanuel Baccelli
6589c01aa0 sys/crypto: remove 3DES 2017-04-25 18:34:18 +02:00
908429eb33 tests: fix misc cppcheck warnings 2017-04-14 14:36:16 +02:00
Oleg Hahm
7ee7801c10 *: remove trailing underscores from header guards 2017-01-19 18:30:53 +01:00
Oleg Hahm
c2893d4a88 sys: crypto: remove twofish and rc5 2017-01-15 14:53:43 +01:00
9082273746 core: header cleanup 2016-02-28 22:46:28 +01:00
Oleg Hahm
51db509f7c sha256: move from crypto to hashes 2016-02-04 14:58:34 +01:00
BytesGalore
59a69796ab unittests/crypto: changed to really compare digest vs string of digest
* added additional test with longer input
* uncrustified file
2016-01-27 06:32:28 +01:00
Nico von Geyso
4a4235c622 Unified Cipher API and Block cipher operation modes 2015-07-22 19:18:34 +02:00
René Kijewski
2cf4253710 sys: add ChaCha stream cipher and PRNG
This implementation is optimized for a little code and data size, not
for speed. IMO the code is more readable than in the reference
implementation.

The biggest advantage of ChaCha over other stream ciphers is the very
little data usage with only 64 bytes of context, and its good encryption
speed.

Also part of this PR is pseudo-random number generator, that just
returns the keystream of a randomly initialized ChaCha context.
2015-06-28 18:32:04 +02:00
Joakim Gebart
13832d8e62 everything: Remove filename from @file Doxygen command 2015-05-22 07:34:41 +02:00
kushalsingh007
88349beb89 Tests: Removing extra newline from Makefile.include
- Removing the extra newline from tests-bloom, tests-crypto and
  tests-timex.
2015-04-16 09:50:03 +05:30
Darredevil
ce46de3799 unittests/tests-crypto: fixed header file include guard
fixes #2623
2015-03-22 16:29:20 +02:00
René Kijewski
f684aa4b2d tests: make embUnit a normal sys module
There is nothing quite special about embUnit.

This PR makes it a normal sys module, so that you can use it in any
application / test.
2014-12-21 20:04:57 +01:00
Philipp Rosenkranz
1024e0b8be tests: transformed tests/sha256 into an unittest 2014-12-11 21:57:01 +01:00