Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | signature-params: Use helper to build MGF1 algorithmIdentifier | Tobias Brunner | 2017-11-08 | 1 | -2/+2 |
| | |||||
* | asn1: Add helper function to create algorithmIdentifier with parameters | Tobias Brunner | 2017-11-08 | 2 | -6/+23 |
| | |||||
* | auth-cfg: Parse rsa/pss auth tokens | Tobias Brunner | 2017-11-08 | 2 | -25/+136 |
| | |||||
* | auth-cfg: Store signature schemes as signature_params_t objects | Tobias Brunner | 2017-11-08 | 7 | -48/+92 |
| | | | | | Due to circular references the hasher_from_signature_scheme() helper does not take a signature_params_t object. | ||||
* | certificate: Return signature scheme and parameters from issued_by() method | Tobias Brunner | 2017-11-08 | 25 | -72/+119 |
| | | | | | This also required some include restructuring (avoid including library.h in headers) to avoid unresolvable circular dependencies. | ||||
* | signature-params: Add helper struct for signature scheme and parameters | Tobias Brunner | 2017-11-08 | 3 | -18/+319 |
| | |||||
* | unit-tests: Add RSA-PSS signature tests with specific salts | Tobias Brunner | 2017-11-08 | 1 | -92/+818 |
| | |||||
* | gcrypt: Add support for static salts when signing with RSA-PSS | Tobias Brunner | 2017-11-08 | 1 | -6/+17 |
| | |||||
* | gmp: Add support for static salts when signing with RSA-PSS | Tobias Brunner | 2017-11-08 | 1 | -2/+6 |
| | |||||
* | signature-params: Optionally pass a specific salt value when signing | Tobias Brunner | 2017-11-08 | 1 | -0/+2 |
| | |||||
* | unit-tests: Warn if we skip RSA tests due to dependencies | Tobias Brunner | 2017-11-08 | 1 | -0/+11 |
| | |||||
* | unit-tests: Add ability to issue a warning message for a test case | Tobias Brunner | 2017-11-08 | 3 | -6/+116 |
| | | | | | This way we can warn if we e.g. skipped actually doing something due to dependencies (otherwise the test case would just appear to have succeeded). | ||||
* | mgf1: Add support for SHA-224/384 based MGF1 | Tobias Brunner | 2017-11-08 | 2 | -1/+11 |
| | |||||
* | xof: Add identifiers for MGF1 XOFs based on SHA-224/384 | Tobias Brunner | 2017-11-08 | 2 | -5/+13 |
| | |||||
* | gmp: Use helper to determine XOF type | Tobias Brunner | 2017-11-08 | 2 | -28/+10 |
| | |||||
* | xof: Add helper to determine MGF1 XOF type from hash algorithm | Tobias Brunner | 2017-11-08 | 2 | -0/+38 |
| | |||||
* | gcrypt: Add support for RSA-PSS signatures | Tobias Brunner | 2017-11-08 | 3 | -31/+127 |
| | | | | | | | | For salt lengths other than 20 this requires 0bd8137e68c2 ("cipher: Add option to specify salt length for PSS verification."), which was included in libgcrypt 1.7.0 (for Ubuntu requires 17.04). As that makes it pretty much useless for us (SHA-1 is a MUST NOT), we require that version to even provide the feature. | ||||
* | gcrypt: Register supported RSA signature/verification schemes | Tobias Brunner | 2017-11-08 | 1 | -0/+16 |
| | |||||
* | gmp: Add support for RSASSA-PSS signature verification | Tobias Brunner | 2017-11-08 | 2 | -2/+140 |
| | |||||
* | gmp: Add support for RSASSA-PSS signature creation | Tobias Brunner | 2017-11-08 | 2 | -0/+130 |
| | |||||
* | unit-tests: Add FIPS 186-4 RSASSA-PSS test vectors | Tobias Brunner | 2017-11-08 | 1 | -0/+1629 |
| | | | | | | | | Since not all implementations allow setting a specific salt value when generating signatures (e.g. OpenSSL doesn't), we are often limited to only using the test vectors with salt length of 0. We also exclude test vectors with SHA-1, SHA-224 and SHA-384. | ||||
* | unit-tests: Create and verify some RSA PSS signatures | Tobias Brunner | 2017-11-08 | 1 | -3/+25 |
| | |||||
* | openssl: Add support for verifying RSASSA-PSS signatures | Tobias Brunner | 2017-11-08 | 2 | -3/+142 |
| | |||||
* | openssl: Add support for creating RSASSA-PSS signatures | Tobias Brunner | 2017-11-08 | 2 | -5/+132 |
| | |||||
* | openssl: Add helper to determine EVP_MD from hash_algorithm_t | Tobias Brunner | 2017-11-08 | 2 | -9/+27 |
| | |||||
* | unit-tests: Add FIPS 186-4 RSA test vectors | Tobias Brunner | 2017-11-08 | 1 | -5/+2428 |
| | | | | Excluding SHA-224 and the stuff from FIPS 186-2 (SHA-1, 1024 bit keys). | ||||
* | gcrypt: Determine missing RSA private key parameters | Tobias Brunner | 2017-11-08 | 1 | -4/+133 |
| | | | | | We only need n, e, and d. The primes p and q and the coefficient for the Chinese remainder algorithm can be determined from these. | ||||
* | gmp: Determine missing RSA private key parameters | Tobias Brunner | 2017-11-08 | 1 | -4/+109 |
| | | | | | We only need n, e, and d. The parameters for the Chinese remainder algorithm and even p and q can be determined from these. | ||||
* | openssl: Add functions to determine missing RSA private key parameters | Tobias Brunner | 2017-11-08 | 1 | -9/+223 |
| | | | | | We only need n, e, and d. The parameters for the Chinese remainder algorithm and even p and q can be determined from these. | ||||
* | signature-params: Add functions to parse/build ASN.1 RSASSA-PSS params | Tobias Brunner | 2017-11-08 | 7 | -1/+421 |
| | |||||
* | hasher: Add function to determine length of hashes | Tobias Brunner | 2017-11-08 | 2 | -0/+46 |
| | |||||
* | asn1: Add function to generate an ASN.1 integer from an uint64_t | Tobias Brunner | 2017-11-08 | 3 | -6/+63 |
| | |||||
* | asn1: Add OID for MGF1 | Tobias Brunner | 2017-11-08 | 1 | -1/+1 |
| | |||||
* | signature-params: Add struct for RSASSA-PSS parameters | Tobias Brunner | 2017-11-08 | 2 | -0/+42 |
| | |||||
* | private-key: Add optional parameters argument to sign() method | Tobias Brunner | 2017-11-08 | 20 | -37/+36 |
| | |||||
* | public-key: Add optional parameters argument to verify() method | Tobias Brunner | 2017-11-08 | 22 | -38/+50 |
| | |||||
* | public-key: Add RSASSA-PSS signature scheme identifier | Tobias Brunner | 2017-11-08 | 3 | -0/+9 |
| | |||||
* | asn1: Add OID for RSASSA-PSS | Tobias Brunner | 2017-11-08 | 1 | -0/+1 |
| | |||||
* | ikev2: Don't use SHA-1 for RFC 7427 signature authentication | Tobias Brunner | 2017-11-08 | 2 | -4/+4 |
| | | | | | | RFC 8247 demoted it to MUST NOT. References #2427. | ||||
* | pkcs11: Call C_Finalize() to cancel jobs waiting in C_WaitForSlotEvent() | Tobias Brunner | 2017-11-02 | 1 | -9/+14 |
| | | | | | | | | | | | | | | | | This is not ideal as the call to C_Finalize() should be the last one via the PKCS#11 API. Since the order in which jobs are canceled is undefined we can't be sure there is no other thread still using the library (it could even be the canceled job that still handles a previous slot event). According to PKCS#11 the behavior of C_Finalize() is undefined while other threads still make calls over the API. However, canceling the thread, as done previously, could also be problematic as PKCS#11 libraries could hold locks while in the C_WaitForSlotEvent() call, which might not get released properly when the thread is just canceled, and which then might cause later calls to other API functions to block. Fixes #2437. | ||||
* | utils: Add helper function to parse time spans from strings | Tobias Brunner | 2017-11-02 | 4 | -42/+132 |
| | |||||
* | asn1: Add additional OIDs seen in certificate DNs | Tobias Brunner | 2017-11-02 | 2 | -0/+6 |
| | |||||
* | openssl: Also load EC keys from an ENGINE | Tobias Brunner | 2017-11-02 | 5 | -155/+168 |
| | |||||
* | streams: Remove registered systemd stream service | Tobias Brunner | 2017-10-18 | 1 | -0/+3 |
| | | | | Fixes: 59db98fb941c ("stream: Add basic stream service for systemd sockets") | ||||
* | streams: Named systemd sockets are only supported since systemd v227 | Tobias Brunner | 2017-10-13 | 1 | -0/+6 |
| | |||||
* | watcher: Don't notify watcher if removed FD was not found | Tobias Brunner | 2017-10-10 | 1 | -2/+6 |
| | | | | | | | | | | | | This can happen if a stream is used blocking exclusively (the FD is never registered with watcher, but is removed in the stream's destructor just in case it ever was - doing this conditionally would require an additional flag in streams). There may be no thread reading from the read end of the notify pipe (e.g. in starter), causing the write to the notify pipe to block after it's full. Anyway, doing a relatively expensive FD update is unnecessary if there were no changes. Fixes #1453. | ||||
* | stream: Add basic stream service for systemd sockets | aszlig | 2017-10-10 | 4 | -0/+118 |
| | | | | | | | | | | | | | | | | | | | | | | | | This allows systemd socket activation by passing URIs such as systemd://foo to plugins such as VICI. For example setting charon.plugins.vici.socket = systemd://vici, a systemd socket file descriptor with the name "vici" will be picked up. So these would be the corresponding unit options: [Socket] FileDescriptorName=vici Service=strongswan.service ListenStream=/run/charon.vici The implementation currently is very basic and right now only the first file descriptor for a particular identifier is picked up if there are multiple socket units with the same FileDescriptorName. Signed-off-by: aszlig <aszlig@redmoonstudios.org> Closes strongswan/strongswan#79. | ||||
* | openssl: Fix call of X509_CRL_get0_signature() with OpenSSL 1.1.0 | Tobias Brunner | 2017-10-10 | 1 | -3/+3 |
| | | | | | | | The order of arguments in X509_CRL_get0_signature() is not the same as that of X509_get0_signature(). Fixes: 989ba4b6cd16 ("openssl: Update CRL API to OpenSSL 1.1.0") | ||||
* | configure: Fix gperf length parameter determination | Tobias Brunner | 2017-10-02 | 3 | -2/+11 |
| | | | | | | | | | | gperf is not actually a build dependency as the generated files are shipped in the tarball. So the type depends on the gperf version on the host that ran gperf and created the tarball, which might not be the same as that on the actual build host, and gperf might not even be installed there, leaving the type undetermined. Fixes: e0e43229736a ("configure: Detect type of length parameter for gperf generated function") | ||||
* | configure: Detect type of length parameter for gperf generated function | Tobias Brunner | 2017-09-19 | 1 | -1/+1 |
| | | | | | Since 3.1 gperf uses size_t for the length parameter instead of an unsigned int. |