Commit Graph

40 Commits

Author SHA1 Message Date
Nicolas Williams 8e9ad6eda2 krb5: Fix UB 2022-11-01 16:10:57 -05:00
Nicolas Williams fb553dde1d krb5: Fix warnings 2022-01-14 17:10:16 -06:00
Luke Howard 7b720cf61c krb5: implement draft-ietf-kitten-aes-cts-hmac-sha2-07 2016-10-08 08:17:11 +02:00
Nicolas Williams 490337f4f9 Make OpenSSL an hcrypto backend proper
This adds a new backend for libhcrypto: the OpenSSL backend.

Now libhcrypto has these backends:

 - hcrypto itself (i.e., the algorithms coded in lib/hcrypto)
 - Common Crypto (OS X)
 - PKCS#11 (specifically for Solaris, but not Solaris-specific)
 - Windows CNG (Windows)
 - OpenSSL (generic)

The ./configure --with-openssl=... option no longer disables the use of
hcrypto.  Instead it enables the use of OpenSSL as a (and the default)
backend in libhcrypto.  The libhcrypto framework is now always used.

OpenSSL should no longer be used directly within Heimdal, except in the
OpenSSL hcrypto backend itself, and files where elliptic curve (EC)
crypto is needed.

Because libhcrypto's EC support is incomplete, we can only use OpenSSL
for EC.  Currently that means separating all EC-using code so that it
does not use hcrypto, thus the libhx509/hxtool and PKINIT EC code has
been moved out of the files it used to be in.
2016-04-15 00:16:17 -05:00
Nicolas Williams 4b37c27515 Make aes-test.c more useful 2016-04-15 00:16:13 -05:00
Love Hörnquist Åstrand 8060a561db switch to KRB5_ENCTYPE 2011-07-24 16:02:22 -07:00
Love Hornquist Astrand 0879b9831a remove trailing whitespace 2011-05-21 11:57:31 -07:00
Love Hornquist Astrand 94cc296741 plug more leaks 2009-09-21 10:08:42 -07:00
Love Hornquist Astrand 80c866a4a7 fix valgrind problems 2009-09-21 09:52:28 -07:00
Love Hörnquist Åstrand c99b2003e2 Implement gss_wrap_iov, gss_unwrap_iov for CFX type encryption types.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@25286 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-06-22 17:56:41 +00:00
Love Hörnquist Åstrand 942a821fab remove RCSID
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@25171 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-05-04 06:17:40 +00:00
Love Hörnquist Åstrand 8fa89322db Only one buffer.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24749 ec53bebd-3082-4978-b11e-865c3cabbd6b
2009-02-16 19:12:44 +00:00
Love Hörnquist Åstrand a5d8671999 heimdal smaller
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23966 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-10-26 18:22:27 +00:00
Love Hörnquist Åstrand 6937d41a02 remove trailing whitespace
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23815 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-09-13 09:21:03 +00:00
Love Hörnquist Åstrand e172367898 switch to utf8 encoding of all files
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23814 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-09-13 08:53:55 +00:00
Love Hörnquist Åstrand f78f1f0ad7 fix index
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23708 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-08-28 01:13:00 +00:00
Love Hörnquist Åstrand 0f18ec866a fix iov useage, check length and padding buffer
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23654 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-08-21 21:25:35 +00:00
Love Hörnquist Åstrand 8ef17f5306 test encryption and decryption.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23651 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-08-21 21:25:00 +00:00
Love Hörnquist Åstrand ffa4cfde5e test krb5_decrypt_iov_ivec
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23646 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-08-21 21:24:07 +00:00
Love Hörnquist Åstrand 7d80d78c9c Moved cts test to hcrypto.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23567 ec53bebd-3082-4978-b11e-865c3cabbd6b
2008-08-16 23:04:18 +00:00
Love Hörnquist Åstrand 3305b31c29 Make argument to PKCS5_PBKDF2_HMAC_SHA1 unsigned char to make OpenSSL happy.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@18301 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-10-07 13:50:34 +00:00
Love Hörnquist Åstrand 3c6cb82e67 Less "pointer targets in passing argument differ in signedness" warnings.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@17509 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-05-08 11:27:49 +00:00
Love Hörnquist Åstrand cbd4c81a98 reformat, avoid free-ing un-init'd memory
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16780 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-02-28 14:51:39 +00:00
Love Hörnquist Åstrand 6e877e22b1 Only use PKCS5_PBKDF2_HMAC_SHA1.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16779 ec53bebd-3082-4978-b11e-865c3cabbd6b
2006-02-28 14:43:27 +00:00
Love Hörnquist Åstrand 116c7fa6f6 Remove usage of krb5_enctype_to_keytype.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@16317 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-11-30 11:25:45 +00:00
Love Hörnquist Åstrand ab541001cc #include <err.h>
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@15036 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-04-30 15:19:58 +00:00
Love Hörnquist Åstrand 401620865e size_t vs int + fix printf
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14725 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-04-04 11:12:31 +00:00
Love Hörnquist Åstrand fdb02ca44d use hex encoder from roken
AES is enabled by default, remove ifdefs


git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@14653 ec53bebd-3082-4978-b11e-865c3cabbd6b
2005-03-17 00:34:12 +00:00
Love Hörnquist Åstrand 2be538b05c test random to key function
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13747 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-04-22 22:09:35 +00:00
Love Hörnquist Åstrand 5f1d7ce89c remove #if 0'ed code
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13583 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-03-20 18:39:53 +00:00
Love Hörnquist Åstrand 1987668bf1 add "next iv" test for aes128, check decryption case too
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13312 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-02-03 21:05:57 +00:00
Love Hörnquist Åstrand b1c7bcffd1 add "next iv" test for aes128
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13310 ec53bebd-3082-4978-b11e-865c3cabbd6b
2004-02-03 20:48:25 +00:00
Love Hörnquist Åstrand 1752eb97e0 move variable thats used within a #ifdef to be defined within that #ifdef
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12730 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-09-02 23:20:46 +00:00
Love Hörnquist Åstrand 0cfe6c3513 add test for krb5_c_encrypt_length and krb5_c_decrypt
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12452 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-07-19 07:40:02 +00:00
Love Hörnquist Åstrand de13634e69 add a test for aes kcrypto encrypted data
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12383 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-06-21 05:45:52 +00:00
Love Hörnquist Åstrand 7d2d92fb04 add aes256 test vectors from Ken Raeburn
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12381 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-06-18 21:42:44 +00:00
Love Hörnquist Åstrand dbcc911afa use _krb5_PKCS5_PBKDF2
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12154 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-04-26 11:42:01 +00:00
Love Hörnquist Åstrand c323190572 add another arcfour test
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11907 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-03-25 11:30:41 +00:00
Love Hörnquist Åstrand c9c606ce8f sneek in a test for arcfour-hmac-md5
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11898 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-03-22 00:09:27 +00:00
Love Hörnquist Åstrand 5d66fae756 add aes-test.c
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@11584 ec53bebd-3082-4978-b11e-865c3cabbd6b
2003-01-15 04:26:29 +00:00