From 5994f14142baaf6982a48e8dec61e591323cd438 Mon Sep 17 00:00:00 2001 From: Paul Park Date: Fri, 16 Jun 1995 21:10:43 +0000 Subject: Inline code from krb_save_credentials since there is none in some K4 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6085 dc483132-0cff-0310-8789-dd5450dbe970 --- src/krb524/ChangeLog | 5 +++++ src/krb524/k524init.c | 18 ++++++++++++++++++ 2 files changed, 23 insertions(+) diff --git a/src/krb524/ChangeLog b/src/krb524/ChangeLog index efd7c90cb4..e63e7fe730 100644 --- a/src/krb524/ChangeLog +++ b/src/krb524/ChangeLog @@ -1,4 +1,9 @@ +Fri Jun 16 17:09:09 EDT 1995 Paul Park (pjpark@mit.edu) + * k524init.c - Inline code from krb_save_credentials, it doesn't + exist for some K4 (e.g. /usr/athena). + + Thu Jun 15 17:56:43 EDT 1995 Paul Park (pjpark@mit.edu) * Makefile.in - Change explicit library names to -l form, and change target link line to use $(LD) and associated flags. diff --git a/src/krb524/k524init.c b/src/krb524/k524init.c index 86d08b9801..25cdafaaa3 100644 --- a/src/krb524/k524init.c +++ b/src/krb524/k524init.c @@ -127,6 +127,7 @@ int main(int argc, char **argv) } } +#ifdef notdef /* stash ticket, session key, etc. for future use */ if ((code = krb_save_credentials(v4creds.service, v4creds.instance, v4creds.realm, v4creds.session, @@ -136,6 +137,23 @@ int main(int argc, char **argv) com_err("k524init", code, "trying to save the V4 ticket"); exit(1); } +#else /* notdef */ + /* + * krb_save_credentials() as supplied by CNS doesn't exist in the MIT + * Kerberos version 4. So, we're inlining the logic here. + */ + if (((code = tf_init(TKT_FILE, W_TKT_FIL)) != KSUCCESS) || + ((code = tf_save_cred(v4creds.service, v4creds.instance, + v4creds.realm, v4creds.session, + v4creds.lifetime, v4creds.kvno, + &(v4creds.ticket_st), + v4creds.issue_date)))) { + com_err("k524init", code, "trying to save the V4 ticket"); + exit(1); + } + else + (void) tf_close(); +#endif /* notdef */ exit(0); } -- cgit