1
1
Граф коммитов

48 Коммитов

Автор SHA1 Сообщение Дата
Aris Adamantiadis
4f5660e081 tests: Add ed25519 OpenSSH key saving
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2015-02-02 14:45:52 +01:00
Aris Adamantiadis
119840b0a9 tests: Add ed25519 OpenSSH key loading and operations
Signed-off-by: Aris Adamantiadis <aris@0xbadc0de.be>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2015-02-02 14:45:52 +01:00
Andreas Schneider
173994786b tests: Fix writing the '\0'.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
2014-08-18 21:41:36 +02:00
Andreas Schneider
25eb9c4914 tests: Use public testkey passphrase function in pki test.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Aris Adamantiadis <aris@0xbadc0de.be>
2014-08-15 12:32:57 +02:00
Andreas Schneider
c673543e54 tests: Use public testkeys in pki test.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Aris Adamantiadis <aris@0xbadc0de.be>
2014-08-15 12:32:51 +02:00
Andreas Schneider
83aed7610c tests: Make write file a public torture function.
Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Aris Adamantiadis <aris@0xbadc0de.be>
2014-08-15 12:32:37 +02:00
Andreas Schneider
8b7627efd5 tests: Make sure we null terminate the buffer.
CID: 1230359

Signed-off-by: Andreas Schneider <asn@cryptomilk.org>
Reviewed-by: Aris Adamantiadis <aris@0xbadc0de.be>
2014-08-15 12:29:23 +02:00
Aris Adamantiadis
0cd0f685c9 torture_pki: avoid generating keys with ssh-keygen
ssh-keygen makes the tests very slow because new keys are generated
at the start of every test.
ssh-keygen on OSX doesn't support ecdsa keys, even if libcrypto does.

Reviewed-by: Andreas Schneider <asn@samba.org>
2014-08-06 10:04:57 +02:00
Jon Simons
48aca98cd5 pki crypto: expose new ssh_pki_key_ecdsa_name API
Enable retrieving the "ecdsa-sha2-nistpNNN" name of ECDSA keys with a
new 'ssh_pki_key_ecdsa_name' API.  This gives more information than the
'ssh_key_type_to_char' API, which yields "ssh-ecdsa" for ECDSA keys.
The motivation is that this info is useful to have in a server context.

The torture_pki unit test is updated to include the new API, and a few
more passes are added to additionally test 384 and 521-bit keys.

Signed-off-by: Jon Simons <jon@jonsimons.org>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2014-04-09 11:01:11 +02:00
Andreas Schneider
fbf73ede1e tests: Check the the ecdsa_nid is the same. 2014-03-27 10:01:12 +01:00
Alan Dunn
577840d7f7 tests: Add test case for bug #147
Signed-off-by: Alan Dunn <amdunn@gmail.com>
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
2014-03-27 10:01:01 +01:00
Andreas Schneider
8b407f1ca2 tests: Fix pki test with gcrypt. 2013-12-11 21:11:49 +01:00
Andreas Schneider
d1d3beac33 tests: Fix memory leaks. 2013-11-28 14:40:11 +01:00
Andreas Schneider
004240af48 tests: Add torture_pki_write_privkey_ecdsa test. 2013-11-27 22:54:13 +01:00
Andreas Schneider
4e3d16e291 tests: Add torture_pki_write_privkey_dsa test. 2013-11-27 22:54:13 +01:00
Andreas Schneider
7933aef747 tests: Add torture_pki_write_privkey_rsa test. 2013-11-27 22:54:13 +01:00
Andreas Schneider
48b715cce0 tests: Use fstat() after the open(). 2013-07-13 13:59:58 +02:00
Andreas Schneider
68be73ec0d tests: Check return value of stat. 2013-06-18 17:11:34 +02:00
Andreas Schneider
679cd9efd8 pki: Fix build if you don't have ECC support. 2012-02-04 18:37:05 +01:00
Andreas Schneider
ae59049347 tests: Test ecdsa key generation and signing. 2012-02-04 18:37:05 +01:00
Andreas Schneider
91372e298d tests: Add duplicate ecdsa key test. 2012-02-04 18:37:04 +01:00
Andreas Schneider
14bb23ae3b tests: Add ecdsa pubkey_from_privkey test. 2012-02-04 18:37:04 +01:00
Andreas Schneider
0e1992a9cc tests: Add ecdsa publickey_from_privatekey test. 2012-02-04 18:37:04 +01:00
Andreas Schneider
fc8a182823 tests: Add a testing of importing ecdsa pubkeys. 2012-02-04 18:37:04 +01:00
Andreas Schneider
d44a79da9b tests: Add test for reading ecdsa privkey. 2012-02-04 18:37:04 +01:00
Andreas Schneider
2c04994443 pki: Add a ssh_key_cmp() function. 2011-10-29 19:58:28 +02:00
Aris Adamantiadis
21d68112b8 Torture: test new ssh_pki_generate function 2011-09-24 01:36:39 +02:00
Andreas Schneider
822c68eb8e pki: Use consistent API for ssh_pki_export_privkey_to_pubkey(). 2011-08-30 10:28:57 +02:00
Andreas Schneider
a98301d2b0 tests: Add pki signature test. 2011-08-21 13:17:30 +02:00
Andreas Schneider
fa4f2d8bc1 tests: Add pki torture tests for keytypes. 2011-08-21 13:13:21 +02:00
Andreas Schneider
c8d06b6b1c tests: Fix memleak in torture_pki. 2011-08-21 12:41:42 +02:00
Andreas Schneider
79029854f6 tests: Added more pki tests. 2011-08-20 12:59:19 +02:00
Andreas Schneider
bac5f62eaf tests: Fix build warning. 2011-08-20 10:54:43 +02:00
Andreas Schneider
e3bd018465 tests: Fix the torture_pki test. 2011-08-20 10:48:34 +02:00
Andreas Schneider
c575de17a8 pki: Use a consistent naming scheme. 2011-08-19 11:14:23 +02:00
Andreas Schneider
3e56ac650c tests: Fix torture_pki build warnings. 2011-08-19 11:14:06 +02:00
Andreas Schneider
765b42e68a tests: Improve pki_import_privkey_base64 test. 2011-08-19 11:03:31 +02:00
Andreas Schneider
2615f8bc94 tests: Added test for pubkey from privkey. 2011-08-16 23:06:13 +02:00
Andreas Schneider
1a0fbedc2e pki: Fix and rename ssh_pki_publickey_to_base64().
Rename it to ssh_pki_export_publickey_base64().
2011-08-16 23:04:25 +02:00
Andreas Schneider
254c30be2e pki: Remove session from ssh_pki_import_pubkey_* functions. 2011-08-16 19:33:24 +02:00
Andreas Schneider
25a2108809 pki: Remove session from ssh_pki_import_privkey_* functions. 2011-08-16 18:53:18 +02:00
Andreas Schneider
f7a7bf071d torture: Fix memleak in pubkey base64 tests. 2011-08-16 09:23:53 +02:00
Andreas Schneider
330c713fdb pki: Add test torture_pki_publickey_dsa_base64(). 2011-08-16 01:17:24 +02:00
Andreas Schneider
9dfef44fd8 pki: Add ssh_pki_publickey_to_base64(). 2011-08-16 00:47:43 +02:00
Andreas Schneider
47ebcac4cd torture: Add torture_pki_publickey_rsa_base64 test. 2011-08-16 00:47:43 +02:00
Andreas Schneider
9569d053d8 pki: Improve ssh_pki_import_privkey_base64(). 2011-08-08 15:28:31 +02:00
Aris Adamantiadis
34b05fd2dc Fix memory leaks in pki and testcase 2011-05-26 21:33:36 +02:00
milo
23aa58e442 Added some tortures for pki 2011-04-14 14:05:44 +02:00