From 594dc81d6e346fe6309c2930da830b809e618b6a Mon Sep 17 00:00:00 2001 From: Ezra Peisach Date: Wed, 7 Jun 1995 01:20:12 +0000 Subject: [PATCH] test.c (do_remote): Case sockaddr_in * to sockaddr * in calling krb524_convert_creds_addr. (krb4_print_ticket): issue_time should be a KRB4_32 encode.c (encode_v4tkt): Cast a the unsigned long mbz field of KTEXT to krb5_int32 for call to encode_int32. conv_creds.c (krb524_convert_creds_addr): Cast sockaddr * to sockaddr_in *. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@5962 dc483132-0cff-0310-8789-dd5450dbe970 --- src/krb524/ChangeLog | 11 +++++++++++ src/krb524/conv_creds.c | 2 +- src/krb524/encode.c | 4 ++-- src/krb524/test.c | 5 +++-- 4 files changed, 17 insertions(+), 5 deletions(-) diff --git a/src/krb524/ChangeLog b/src/krb524/ChangeLog index 2d923e224..e859d8564 100644 --- a/src/krb524/ChangeLog +++ b/src/krb524/ChangeLog @@ -1,3 +1,14 @@ +Tue Jun 6 20:59:56 1995 Ezra Peisach + + * test.c (do_remote): Case sockaddr_in * to sockaddr * in calling + krb524_convert_creds_addr. + (krb4_print_ticket): issue_time should be a KRB4_32 + + * encode.c (encode_v4tkt): Cast a the unsigned long mbz field of + KTEXT to krb5_int32 for call to encode_int32. + + * conv_creds.c (krb524_convert_creds_addr): Cast sockaddr * to + sockaddr_in *. Tue Jun 6 17:25:20 EDT 1995 Paul Park (pjpark@mit.edu) * Makefile.in : Change $(ARCHIVE) to $(ARADD) so that updates to the diff --git a/src/krb524/conv_creds.c b/src/krb524/conv_creds.c index 1b79fc04b..dce260ef3 100644 --- a/src/krb524/conv_creds.c +++ b/src/krb524/conv_creds.c @@ -49,7 +49,7 @@ int krb524_convert_creds_addr(context, v5creds, v4creds, saddr) return krb524_convert_tkt(v5creds->server, &v5creds->ticket, &v4creds->ticket_st, &v4creds->kvno, - saddr); + (struct sockaddr_in *) saddr); } int krb524_convert_creds_kdc(context, v5creds, v4creds) diff --git a/src/krb524/encode.c b/src/krb524/encode.c index 871cf9f05..45e685d3e 100644 --- a/src/krb524/encode.c +++ b/src/krb524/encode.c @@ -76,7 +76,7 @@ int encode_v4tkt(KTEXT_ST *v4tkt, char *buf, int *encoded_len) return ret; if ((ret = encode_bytes(&buf, &buflen, v4tkt->dat, MAX_KTXT_LEN))) return ret; - if ((ret = encode_int32(&buf, &buflen, &v4tkt->mbz))) + if ((ret = encode_int32(&buf, &buflen, (krb5_int32 *) &v4tkt->mbz))) return ret; *encoded_len -= buflen; @@ -115,7 +115,7 @@ int decode_v4tkt(KTEXT_ST *v4tkt, char *buf, int *encoded_len) return ret; if ((ret = decode_bytes(&buf, &buflen, v4tkt->dat, MAX_KTXT_LEN))) return ret; - if ((ret = decode_int32(&buf, &buflen, &v4tkt->mbz))) + if ((ret = decode_int32(&buf, &buflen, (krb5_int32 *) &v4tkt->mbz))) return ret; *encoded_len -= buflen; return 0; diff --git a/src/krb524/test.c b/src/krb524/test.c index e6d8744c5..fee06c2f5 100644 --- a/src/krb524/test.c +++ b/src/krb524/test.c @@ -135,7 +135,8 @@ void krb4_print_ticket(KTEXT ticket, krb5_keyblock *secret_key) char pname[ANAME_SZ], pinst[INST_SZ], prealm[REALM_SZ]; char sname[ANAME_SZ], sinst[INST_SZ]; unsigned char flags; - unsigned long addr, issue_time; + unsigned long addr; + unsigned KRB4_32 issue_time; C_Block session_key; int life; Key_schedule keysched; @@ -292,7 +293,7 @@ void do_remote(krb5_context context, krb5_creds *v5creds, char *server, sizeof(struct in_addr)); if ((ret = krb524_convert_creds_addr(context, v5creds, &v4creds, - &saddr))) { + (struct sockaddr *) &saddr))) { com_err("test", ret, "converting credentials on %s", server); exit(1); -- 2.26.2