Andreas Steffen
4f19112b1f
Moved Ed25519 tests to libstrongswan
2016-12-14 11:57:36 +01:00
Andreas Steffen
e9c2b6658b
unit-tests: Completed coverage of hasher, crypter and libnttfft
2016-12-14 11:15:48 +01:00
Andreas Steffen
40f2589abf
gmp: Support of SHA-3 RSA signatures
2016-09-22 17:34:31 +02:00
Andreas Steffen
188b190a70
mgf1: Refactored MGF1 as an XOF
2016-09-21 06:40:52 +02:00
Tobias Brunner
b82b5f6398
chunk: Skip all leading zero bytes in chunk_skip_zero() not just the first
2016-04-04 15:39:42 +02:00
Tobias Brunner
85597f2983
string: Gracefully handle NULL in str*eq() macros
2016-04-04 10:43:46 +02:00
Andreas Steffen
b12c53ce77
Use standard unsigned integer types
2016-03-24 18:52:48 +01:00
Andreas Steffen
1d86d1d65a
Implemented IPv4/IPv6 subnet and range identities
...
The IKEv1 IPV4_ADDR_SUBNET, IPV6_ADDR_SUBNET, IPV4_ADDR_RANGE and
IPV6_ADDR_RANGE identities have been fully implemented and can be
used as owners of shared secrets (PSKs).
2016-03-10 13:59:37 +01:00
Tobias Brunner
348b0ffbc6
linked-list: Add method to compare two lists of objects for equality
2016-03-08 10:21:57 +01:00
Tobias Brunner
3c23a75120
auth-cfg: Make IKE signature schemes configurable
...
This also restores the charon.signature_authentication_constraints
functionality, that is, if no explicit IKE signature schemes are
configured we apply all regular signature constraints as IKE constraints.
2016-03-04 16:19:54 +01:00
Tobias Brunner
fbbbe43ec1
unit-tests: The pseudonym RDN is now recognized, so use something more exotic
2016-01-28 16:01:24 +01:00
Martin Willi
01caed533b
array: Add an insert/create function for value based arrays
2015-12-07 10:05:07 +01:00
Tobias Brunner
8623ae9fc6
settings: Add settings_value_as_uint64() helper function
2015-11-11 15:39:49 +01:00
Tobias Brunner
ebeb8c87c5
traffic-selector: Don't end printf'ed list of traffic selectors with a space
2015-11-10 12:13:06 +01:00
Andreas Steffen
23a50e66f1
testing: Updated hasher tests
2015-11-06 16:05:44 +01:00
Andreas Steffen
a88d958933
Explicitly mention SHA2 algorithm in BLISS OIDs and signature schemes
2015-11-06 14:55:31 +01:00
Tobias Brunner
dc486823aa
unit-tests: Add a test to verify that there is no partial matching of RDNs
2015-09-09 14:39:26 +02:00
Tobias Brunner
7a1fed284c
Fixed some typos, courtesy of codespell
2015-08-27 12:06:31 +02:00
Tobias Brunner
0737e936e0
unit-tests: Additional test cases to increase coverage
2015-08-27 11:47:36 +02:00
Tobias Brunner
520fba4899
identification: Add hash() method
...
Compared to hashing the encoding we can ignore string types of RDNs when
hashing DNs, making hash() compatible to equals() that does the same.
Fixes #991 .
2015-08-06 17:22:32 +02:00
Tobias Brunner
d29a4a5e20
unit-tests: Add unit tests for settings_t.load_string[_section]
2015-07-28 13:27:32 +02:00
Tobias Brunner
764960e8b9
settings: Add support for multi-line strings
...
Unterminated strings are now an error.
2015-07-28 13:27:32 +02:00
Tobias Brunner
65579569ad
host: Properly handle NULL in host_create_from_string[_and_family]
2015-07-27 11:53:26 +02:00
Tobias Brunner
523ea82ed5
unit-tests: Add tests for iv_gen_seq_t
2015-06-05 13:44:42 +02:00
Martin Willi
31a171f5c4
unit-tests: Further increase the test vector testing timeout
...
Some build bots running make check seem to have longer for the DH testing.
2015-04-16 10:15:13 +02:00
Martin Willi
e507c48e8d
unit-tests: Use progressive testing of transforms with test vectors
...
This allows us to show which transform from which plugin failed. Also, we use
the new cleanup handler functionality that allows proper deinitialization on
failure or timeout.
2015-04-15 14:38:43 +02:00
Martin Willi
de1c492a0f
enum-names: Fail gracefully when passing a NULL value as enum names
2015-04-15 14:38:43 +02:00
Martin Willi
d36b30803e
thread: Add a function to pop and call all registered cleanup handlers
2015-04-15 14:38:43 +02:00
Martin Willi
26c215e818
unit-tests: Use a larger timeout for test vector testing
...
As we test DH calculations this now takes more time. If multiple DH backends
are enabled, we likely hit the default test timeout.
2015-04-15 14:38:42 +02:00
Martin Willi
f206bb7444
utils: Add malloc/free wrappers returning aligned data
...
While we could use posix_memalign(3), that is not fully portable. Further, it
might be difficult on some platforms to properly catch it in leak-detective,
which results in invalid free()s when releasing such memory.
We instead use a simple wrapper, which allocates larger data, and saves the
padding size in the allocated header. This requires that memory is released
using a dedicated function.
To reduce the risk of invalid free() when working on corrupted data, we fill up
all the padding with the padding length, and verify it during free_align().
2015-04-15 13:44:40 +02:00
Martin Willi
9d6e952201
utils: Add a constant time chunk_equals() variant for cryptographic purposes
2015-04-14 12:02:48 +02:00
Martin Willi
b833963270
utils: Add a constant time memeq() variant for cryptographic purposes
2015-04-14 11:51:54 +02:00
Martin Willi
a777155ffe
diffie-hellman: Add a bool return value to set_other_public_value()
2015-03-23 17:54:03 +01:00
Martin Willi
42431690e0
diffie-hellman: Add a bool return value to get_my_public_value()
2015-03-23 17:54:03 +01:00
Martin Willi
bace1d6479
diffie-hellman: Use bool instead of status_t as get_shared_secret() return value
...
While such a change is not unproblematic, keeping status_t makes the API
inconsistent once we introduce return values for the public value operations.
2015-03-23 17:54:02 +01:00
Tobias Brunner
cb461de2a2
unit-tests: Fix settings test after merging multi-line strings
2015-03-23 10:46:32 +01:00
Martin Willi
e284a861b8
unit-tests: Depend on SHA1/SHA256 features for mgf1 test cases
2015-03-23 09:53:34 +01:00
Tobias Brunner
1f648d756b
public-key: Add helper to determine acceptable signature schemes for keys
2015-03-04 13:54:10 +01:00
Thomas Egerer
4dc72f5e57
enum: Extend printf hook to print flags
...
Signed-off-by: Thomas Egerer <[email protected] >
2015-03-03 13:41:49 +01:00
Martin Willi
53013b5f0c
unit-tests: Don't fail host_create_from_dns() test if IPv6 not supported
...
On some systems, such as the Ubuntu daily build machine, localhost does not
resolve to an IPv6 address. Accept such a lookup failure.
2015-03-02 14:05:44 +01:00
Andreas Steffen
27bd0fed93
Allow SHA256 and SHA384 data hash for BLISS signatures.
...
The default is SHA512 since this hash function is also
used for the c_indices random oracle.
2015-02-26 08:56:12 +01:00
Martin Willi
0ae862efd1
unit-tests: Add host_create_from_dns() test cases resolving "localhost"
2015-02-24 15:56:37 +01:00
Martin Willi
67a9744bb9
unit-tests: Accept numerical protocol/port numbers in traffic selector tests
2015-02-23 18:44:26 +01:00
Martin Willi
fc978f192f
unit-tests: Add an initial set of traffic selector unit tests
2015-02-20 13:34:48 +01:00
Andreas Steffen
ee3b135687
unit-tests: Adapted to coverity fixes
2014-12-23 15:40:01 +01:00
Andreas Steffen
72bb7eec9c
Implemented get_byte() method for mgf1_bitspender class
...
The new get_byte() method returns a pseudo-random byte at a time.
Changed the get_bits() interface to the same interface as get_byte().
Updated the mgf1 unit-tests accordingly.
2014-11-29 14:51:16 +01:00
Andreas Steffen
37bfe44358
unit-tests: Created separate mgf1 test suite
2014-11-29 14:51:16 +01:00
Andreas Steffen
1d3e080877
Moved mgf1 class to libstrongswan/crypto/mgf1
2014-11-29 14:51:15 +01:00
Martin Willi
f518b52c2d
unit-tests: Test cancellability of some cancellation points we rely on
2014-11-21 12:02:07 +01:00
Tobias Brunner
cd67cd70c8
host: Ignore spaces around - when parsing ranges
2014-10-30 12:32:45 +01:00