summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Prevent applications from combining legacy versions of TLS with TLS1.3tmp-tls10-tls13-fixNikos Mavrogiannopoulos2018-11-273-10/+34
| | | | | | | | | | | | It can happen that an application due to a misconfiguration, enables TLS1.3 in combination with TLS1.0 or TLS1.1 only. In that case a server which is unaware of the TLS1.3 protocol will reply by selecting the TLS1.2 protocol instead and that answer will be rejected by the client. With this change we ensure that TLS1.3 is not enabled in these problematic scenarios. Resolves: #621 Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
* Merge branch 'pem-notext' into 'master'Dmitry Eremin-Solenikov2018-11-2713-82/+201
|\ | | | | | | | | | | | | certtool: don't output textual information if --no-text was given Closes #487 See merge request gnutls/gnutls!810
| * cert-tests: verify --no-text switch for pkcs7/pkcs12 infoDmitry Eremin-Solenikov2018-11-262-0/+28
| | | | | | | | Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * certtool: don't output textual information if --no-text was givenDmitry Eremin-Solenikov2018-11-262-16/+21
| | | | | | | | | | | | | | Disable text output if --no-text option was given for --p7-info and --p12-info. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * certtool: don't output pkcs12 information to stderrDmitry Eremin-Solenikov2018-11-262-10/+12
| | | | | | | | | | | | Print all pkcs12-info output to outfile, rather than stderr. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * cert-tests: verify --no-text switch for cert/crq/pub/privkeysDmitry Eremin-Solenikov2018-11-264-0/+86
| | | | | | | | Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * certtool: don't output textual information if --no-text was givenDmitry Eremin-Solenikov2018-11-266-61/+59
|/ | | | | | | | | Change privkey/certificate/CRL/CSR handling to disable text output if --no-text option was given. Closes #487 Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
* Merge branch 'tmp-minor-fixes' into 'master'Daiki Ueno2018-11-266-103/+106
|\ | | | | | | | | Minor fixes towards 3.6.5 See merge request gnutls/gnutls!818
| * doc: suggest to check max_early_data_size before sending early dataDaiki Ueno2018-11-261-5/+11
| | | | | | | | Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * tests: resume: suppress compiler warningsDaiki Ueno2018-11-261-4/+1
| | | | | | | | Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * .gitignore: ignore more files and sort them alphabeticallyDaiki Ueno2018-11-241-77/+90
| | | | | | | | Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * bootstrap.conf: add "autogen" to buildreqTim Rühsen2018-11-241-0/+1
| | | | | | | | Signed-off-by: Tim Rühsen <tim.ruehsen@gmx.de>
| * build: fix srcdir detection when VPATH buildDaiki Ueno2018-11-241-7/+3
| | | | | | | | | | | | | | Unlike the ".c.c.bak:" and ".h.h.bak:" rules, ".def.stamp:" needs this adjustment because the source files (*.bak) are not provided as $<. Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * tests: remove unnecessary session creation in tls13/anti_replayDaiki Ueno2018-11-241-10/+0
|/ | | | | | | This test only checks the behavior of _gnutls_anti_replay_check, thus session is not needed at all. Signed-off-by: Daiki Ueno <dueno@redhat.com>
* doc: corrected typos [ci skip]Nikos Mavrogiannopoulos2018-11-211-4/+4
| | | | Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
* tests: added test for RSA decryption under gnutls_privkey_import_ext4Nikos Mavrogiannopoulos2018-11-201-17/+40
| | | | Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
* crypto-self-tests-pk: added RSA-PSS sign/verify testsNikos Mavrogiannopoulos2018-11-201-16/+28
| | | | | | | | | This also corrects the GOST R 34.10-2012-512-TC26-512-A self test. Relates: #597 Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
* Merge branch 'tmp-eddsa-pkcs11' into 'master'Nikos Mavrogiannopoulos2018-11-1910-25/+490
|\ | | | | | | | | | | | | Added support for Ed25519 keys under PKCS#11 Closes #417 See merge request gnutls/gnutls!812
| * tests: added TLS1.3 tests for PKCS#11 and external key typesNikos Mavrogiannopoulos2018-11-192-19/+95
| | | | | | | | Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
| * Add support for EDDSA/Ed25519 object support via PKCS#11Simo Sorce2018-11-198-4/+394
| | | | | | | | | | | | | | | | | | Tested with softHSM 2.5.0 Resolves #417 Signed-off-by: Simo Sorce <simo@redhat.com> Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
| * Fix RSA-PSS tests to properly return skip valueSimo Sorce2018-11-191-2/+1
| | | | | | | | Signed-off-by: Simo Sorce <simo@redhat.com>
* | Merge branch 'tmp-fix-certificate-type' into 'master'Nikos Mavrogiannopoulos2018-11-196-32/+50
|\ \ | |/ |/| | | | | gnutls_certificate_type_get*: ensure that the default type is returned See merge request gnutls/gnutls!806
| * gnutls_certificate_type_get*: updated documentation to list limitationstmp-fix-certificate-typeNikos Mavrogiannopoulos2018-11-191-16/+23
| | | | | | | | Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
| * tests: resume: use spaces around '?' and ':' according to coding styleNikos Mavrogiannopoulos2018-11-192-6/+7
| | | | | | | | | | | | Also set a link to the kernel coding style in CONTRIBUTIONS.md Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
| * gnutls_certificate_type_get*: ensure that the default type is returnedNikos Mavrogiannopoulos2018-11-184-10/+20
| | | | | | | | | | | | | | | | | | | | | | | | That is, ensure that unless we negotiate something else than X509, the default certificate type is returned to applications. Previously we wouldn't do that for TLS1.3 resumed sessions, and we would return zero (invalid type) instead. That addresses issues with applications checking explicitly for X509 certificate type being present. Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
* | Merge branch 'tmp-fix-max-early-data-size' into 'master'Nikos Mavrogiannopoulos2018-11-197-13/+77
|\ \ | |/ |/| | | | | Fix max_early_data_size handling See merge request gnutls/gnutls!811
| * tests/tls13-early-data: check if max_early_data_size is advertisedtmp-fix-max-early-data-sizeDaiki Ueno2018-11-181-7/+27
| | | | | | | | Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * serv: add --maxearlydata optionDaiki Ueno2018-11-183-1/+35
| | | | | | | | | | | | Also exercise this in testcompat-tls13-openssl.sh. Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * record: gnutls_record_send_early_data: check the upper limitDaiki Ueno2018-11-181-1/+10
| | | | | | | | Signed-off-by: Daiki Ueno <dueno@redhat.com>
| * tls13/session_ticket: fix "max_early_data_size" extension handlingDaiki Ueno2018-11-182-4/+5
|/ | | | | | session->security_parameters.max_early_data_size is initially set to 0. Signed-off-by: Daiki Ueno <dueno@redhat.com>
* update documentation on GNUTLS_AUTO_REAUTH and gnutls_record_get_direction ↵Nikos Mavrogiannopoulos2018-11-172-9/+14
| | | | | | | | | | | [ci skip] That clarifiesthe intention, and adds warning of using this flag when multiple threads are involved. Based on suggestion by Michael Catanzaro. Relates: #615 Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
* .gitlab-ci.yml: run coverage build over fedoraNikos Mavrogiannopoulos2018-11-161-2/+2
| | | | | | This will include the TPM subsystem in the coverage report. Signed-off-by: Nikos Mavrogiannopoulos <nmav@gnutls.org>
* Merge branch 'tpm12_testing' into 'master'Nikos Mavrogiannopoulos2018-11-167-0/+477
|\ | | | | | | | | tests: tpm: Add a test case for tpmtool See merge request gnutls/gnutls!807
| * tests: tpm: Extend test case to not use --registerStefan Berger2018-11-161-40/+73
| | | | | | | | | | | | | | Extend the tpmtool test case to also test without the --register parameter. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
| * tests: tpm: Add a test case for tpmtoolStefan Berger2018-11-164-0/+432
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This test case exercises tpmtool and uses certtool to create a self-signed certificate with the TPM. It uses swtpm as TPM emulator and configures tcsd to talk to swtpm. Extend the Readme.md with the packages needed for TPM support and TPM test support. This test case needs to be run as root since tcsd needs to be started as root. Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
| * .gitlab-ci.yml: copy the log files of minimal.Fedora to the gitlab serverStefan Berger2018-11-161-0/+9
| | | | | | | | Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
| * lib: tpm: Fix a memory leakStefan Berger2018-11-151-0/+1
| | | | | | | | Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
| * tpmtool: Fix a memory leak related to TPM key listStefan Berger2018-11-151-0/+2
| | | | | | | | Signed-off-by: Stefan Berger <stefanb@linux.ibm.com>
* | Merge branch 'gost-raw-privkeys' into 'master'Nikos Mavrogiannopoulos2018-11-1624-7/+440
|\ \ | | | | | | | | | | | | Improve support of GOST private keys parsing See merge request gnutls/gnutls!802
| * | doc: mention GOST private key unmasking and additional format supportDmitry Eremin-Solenikov2018-11-161-0/+3
| | | | | | | | | | | | Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * | cert-tests: test parsing and decoding of GOST private keysDmitry Eremin-Solenikov2018-11-1615-2/+321
| | | | | | | | | | | | | | | | | | | | | Add a test for parsing and decoding GOST private keys in different formats, incuding encrypted keys. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * | certtool: support --pkcs-cipher noneDmitry Eremin-Solenikov2018-11-161-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | If password is specified on command line currently certtool will always output encrypted pkcs8 file. Add `--pkcs-cipher none' allowing one to force certtool to output unencrypted private keys. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * | nettle/gost: gostdsa: use size_t instead of mp_limb_tDmitry Eremin-Solenikov2018-11-162-2/+2
| | | | | | | | | | | | | | | | | | | | | Use size_t for size variables instead of mp_limb_t (data type rather than size type). Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * | pkcs8: support GOST keys without encapsulationDmitry Eremin-Solenikov2018-11-161-2/+22
| | | | | | | | | | | | | | | | | | | | | | | | Add support for yet another representation of GOST private keys: LE-formatted number encoded into pkcs-8-PrivateKeyInfo.privateKey without any additional encapsulation. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * | nettle: unmaks GOST private keys if necessaryDmitry Eremin-Solenikov2018-11-161-0/+3
| | | | | | | | | | | | Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
| * | nettle/gost: support GOST key unmaskingDmitry Eremin-Solenikov2018-11-163-1/+87
| | | | | | | | | | | | | | | | | | | | | | | | New Russian reccomendation defines 'key masking' in the form of several concatenated numbers, which must be multiplied modulo Q to get private key. Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
* | | Merge branch 'tmp-anti-replay-updates' into 'master'Nikos Mavrogiannopoulos2018-11-1617-83/+596
|\ \ \ | |/ / |/| | | | | | | | | | | | | | updates in anti-replay subsystem Closes #610 See merge request gnutls/gnutls!805
| * | updated auto-generated-filestmp-anti-replay-updatesNikos Mavrogiannopoulos2018-11-153-4/+8
| | | | | | | | | | | | Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
| * | anti_replay: moved new add function into anti_replay structureNikos Mavrogiannopoulos2018-11-1513-87/+117
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The new function was not sharing anything with the existing gnutls_db_* backend, and moving it to anti_replay structure is more clean and allows for deviations from the old API conventions (e.g., now we can pass pointers for efficiency and pass the expiration time as part of the call). Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>
| * | tests: added a test for detecting duplicate early dataNikos Mavrogiannopoulos2018-11-152-1/+480
| | | | | | | | | | | | | | | | | | Resolves #610 Signed-off-by: Nikos Mavrogiannopoulos <nmav@redhat.com>