Commit | Line | Data |
---|---|---|
3cf9afd3 C |
1 | /* |
2 | * $Source: /usr/src/kerberosIV/krb/RCS/pkt_cipher.c,v $ | |
3 | * $Author: kfall $ | |
4 | * | |
5 | * Copyright 1985, 1986, 1987, 1988 by the Massachusetts Institute | |
6 | * of Technology. | |
7 | * | |
8 | * For copying and distribution information, please see the file | |
9 | * <mit-copyright.h>. | |
10 | */ | |
11 | ||
12 | #ifndef lint | |
13 | static char *rcsid_pkt_cipher_c = | |
14 | "$Header: /usr/src/kerberosIV/krb/RCS/pkt_cipher.c,v 4.9 90/06/25 20:57:02 kfall Exp $"; | |
15 | #endif /* lint */ | |
16 | ||
17 | #include <mit-copyright.h> | |
18 | #include <des.h> | |
19 | #include <krb.h> | |
20 | #include <prot.h> | |
21 | ||
22 | ||
23 | /* | |
24 | * This routine takes a reply packet from the Kerberos ticket-granting | |
25 | * service and returns a pointer to the beginning of the ciphertext in it. | |
26 | * | |
27 | * See "prot.h" for packet format. | |
28 | */ | |
29 | ||
30 | KTEXT | |
31 | pkt_cipher(packet) | |
32 | KTEXT packet; | |
33 | { | |
34 | unsigned char *ptr = pkt_a_realm(packet) + 6 | |
35 | + strlen((char *)pkt_a_realm(packet)); | |
36 | /* Skip a few more fields */ | |
37 | ptr += 3 + 4; /* add 4 for exp_date */ | |
38 | ||
39 | /* And return the pointer */ | |
40 | return((KTEXT) ptr); | |
41 | } |