Commit Graph

596 Commits

Author SHA1 Message Date
Nicolas Williams
bbaae5f43c Fix 32-bit time_t regression (#220) 2016-12-06 22:44:23 -06:00
Jeffrey Altman
2fda484c2f kuser: generate_requests leaks 'words'
Change-Id: I67a4b4cdab5bf32b9d2b28d8429bb31202cd3b6b
2016-11-18 23:06:04 -05:00
Jeffrey Altman
5debfae6d1 er: klist print_tickets leaks 'str'
Change-Id: Ie86f3a9d64ceb6d44cd36be06700194b978247c9
2016-11-18 23:04:06 -05:00
Jeffrey Altman
26dd1edaa9 kswitch: memory leaks
ids and name must be freed before they go out of scope.

Change-Id: I0133c27994f7dc2832cea6b8529c060ed779c2ab
2016-11-18 22:51:59 -05:00
Nicolas Williams
7fa85e6d6d Round #3 of scan-build warnings cleanup 2016-11-16 23:27:27 -06:00
Jeffrey Altman
a013e93e95 default life/renewlife time to KDC policy
Instead of imposing a default 10 hour ticket lifetime and 1 month renew
lifetime when requesting tickets, increase the default lifetime and
renew lifetime to 2147483647 seconds.  This ensures that in the absence
of any other configuration or command line parameters that the KDC will
determine the ticket lifetime and renew lifetime.

Change-Id: I52b6eeac1ee830a9bf4d0130e8f4ec7b70bc8694
Signed-off-by: Nicolas Williams <nico@twosigma.com>
2016-11-10 16:13:10 -06:00
Nicolas Williams
0561396c0a Add how-to-test example to kimpersonate.8 2016-08-08 14:14:04 -05:00
Nicolas Williams
ab61e1d395 Add --add and --referral options to kimpersonate 2016-08-08 14:14:04 -05:00
Nicolas Williams
345333c40a Document kimpersonate --ccache option 2016-08-08 14:14:04 -05:00
Nicolas Williams
6d1571a3c4 Fix --disable-afs-support disable lib/kafs 2016-08-04 18:51:23 -05:00
David Mulder
d8080162ea --disable-afs-support doesn't really disable afs 2016-08-02 12:58:26 -06: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
b4cf4de807 Fix warnings (clang 3.6) 2016-02-26 01:04:31 -06:00
Sergio Gelato
50e2a5ce95 (patch) man page syntax errors
A few fixes for syntax errors in man pages, as reported by lintian:

Signed-off-by: Love Hörnquist Åstrand <lha@h5l.org>
2015-05-26 16:03:00 +02:00
Nicolas Williams
a449b7ef5e Store default NTLM domain cc config
This is needed so that the NTLM GSS mechanism can have a meaningful
concept of default credential (the NTLM key for the default domain found
in the ccache).
2015-04-17 10:51:51 -05:00
Nicolas Williams
6001e2adbc kgetcred.1 better describe referrals 2015-04-13 16:59:21 -05:00
Nicolas Williams
e695766d65 Add kgetcred --no-store and --cached-only options
These are useful for diagnostics and for exercising more krb5 get
credentials API options.
2015-04-13 16:59:21 -05:00
Nicolas Williams
50615d2a37 Add --hostbased and --canonical kgetcred options 2015-04-13 16:59:20 -05:00
Nicolas Williams
0306d70a91 Add --debug option to kgetcred 2015-04-13 16:59:20 -05:00
Nicolas Williams
c2961ced3c Fix leak in kimpersonate 2015-04-13 16:59:20 -05:00
Nicolas Williams
4ae3e7d40a Fix leak in kgetcred 2015-04-13 16:59:20 -05:00
Nicolas Williams
333c6fe95d Fix leak in kinit 2015-03-24 11:50:03 -05:00
Nicolas Williams
b81f16abf6 Fix memleak in kswitch rare error 2015-03-24 11:50:03 -05:00
Nicolas Williams
89aed008a9 Fix memleak in kswitch 2015-03-24 11:50:01 -05:00
Roland C. Dowdeswell
92aad0fa3d Fix kinit.1's synopsis w.r.t. -f and -F. 2014-12-01 12:40:54 -05:00
Love Hörnquist Åstrand
37afa01be3 rename roken base64, fixes #107 2014-08-22 20:57:24 -07:00
Love Hörnquist Åstrand
a84b572747 resurrect password change support again 2014-08-22 20:19:36 -07:00
Viktor Dukhovni
6501ba7e95 Avoid appearance of if if else ambiguity 2014-07-22 18:03:04 -04:00
Viktor Dukhovni
d75e74b2d7 Avoid kinit NPE when default cred not in keytab 2014-07-22 17:57:17 -04:00
Jelmer Vernooij
ea062e4bb2 Remove references to KRBTKFILE from login.1 and kinit.1. 2014-06-02 00:32:37 +02:00
Jelmer Vernooij
7e81485562 Remove kerberos 4 references from kimpersonate.8. 2014-06-01 23:21:52 +02:00
Ken Dreyer
9dd7e27bf7 klist: fix spelling in comments 2014-05-28 14:34:06 -06:00
Jeffrey Altman
69c2872dbd kinit: get_switched_ccache
Provide a new internal function called get_switched() to encapsulate
the algorithm for selecting a credential cache when the selected
ccache type supports switching.  There is no change in behavior for
UNIX which always calls krb5_cc_new_unique().  However, on Windows
alternate behavior is provided when the ccache type is API or MSLSA.

For the API ccache the default ccache name is stored in the Windows
registry which is shared across all logon sessions belonging to a
user.  For users that are members of the Administrators group this
includes both the UAC restricted and elevated sessions sharing the
same desktop.  It is very disconcerting when the elevated session obtains
credentials for the same client principal as the restricted session
and then all apps in the restricted session lose access to their
credential cache.   For Windows, the API credential caches are named
after the principal that is stored within them.  It provides for a
better end user experience.

For the MSLSA ccache tickets belonging to multiple principals are
all stored within the MSLSA ccache.  As a result, all attempts to
switch ccache names default back to the one and only one name.

Change-Id: I7865cd044cff01ff38ab107ec0961e42788fa073
2014-05-14 21:52:35 -04:00
Ingo Schwarze
b7d384392b fix the kswitch(1) manual prologue
Signed-off-by: Love Hörnquist Åstrand <lha@h5l.org>
2014-01-31 08:38:04 +01:00
Viktor Dukhovni
b09e1a137b Use defrealm in last-resort parse of kt principal 2013-10-11 20:54:46 -04:00
Viktor Dukhovni
c6548bc166 Don't deref NULL pointer with klist -t 2013-10-03 20:41:49 -04:00
Love Hornquist Astrand
1b39c562d5 use STDERR_FILENO instead of 2 2013-09-27 08:24:51 -07:00
Viktor Dukhovni
2ccdebdacc Fix kinit renew vs. new strategy.
The previous code never obtained a new TGT when -l was not used.
2013-09-23 11:02:08 -04:00
Nicolas Williams
129b4f3720 Fix warning in ! NO_AFS case 2013-09-12 12:14:42 -05:00
Nicolas Williams
c9d390acac Don't use "if (!ret)" 2013-09-12 12:14:41 -05:00
Nicolas Williams
8696739102 Add SIGINFO support for kinit cmd
Use SIGUSR1 if there's no SIGINFO, so the code isn't dead.
2013-09-12 12:14:41 -05:00
Nicolas Williams
6d5741d03b kinit cmd: back-off more slowly and warn
Also refactor AFS klog code so we do it only once on renew.
2013-09-12 12:14:41 -05:00
Nicolas Williams
79ca0dfe75 kinit should save cc configs if it krb5_cc_move()s
Also, renew_validate() should krb5_cc_new_unique() and krb5_cc_move() it
into place.
2013-09-12 12:14:41 -05:00
Nicolas Williams
8ce9a1d686 Allow batch mode in kinit with password file 2013-09-12 12:14:41 -05:00
Nicolas Williams
13c8a2c212 Make kinit cmd not exit on transient errors 2013-09-12 12:14:40 -05:00
Nicolas Williams
c5867bde0e Add options to kcpytkt and kdeltkt for exp tix 2013-09-12 12:14:40 -05:00
Nicolas Williams
d03e8cd91d Use krb5_timeofday() in kuser/copy_cred_cache.c 2013-09-12 12:14:40 -05:00
Love Hornquist Astrand
3e0fd6449e /sess-/session-/g since a few extra letter makes it easier to understand 2013-09-03 21:56:04 -07:00
Harald Barth
502b33ca7f kimpersonate sessionkeyoption and afsdes
Signed-off-by: Love Hornquist Astrand <lha@h5l.org>
2013-09-03 21:53:31 -07:00
Love Hornquist Astrand
a1168815ec use krb5_cc_get_lifetime 2013-07-16 14:42:24 +02:00