blob: f432c601396f76befd05a8f25ad6268bc48e5f0a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
krb5_c_make_checksum - Compute a checksum (operates on keyblock).
===================================================================
..
.. c:function:: krb5_error_code krb5_c_make_checksum(krb5_context context, krb5_cksumtype cksumtype, const krb5_keyblock * key, krb5_keyusage usage, const krb5_data * input, krb5_checksum * cksum)
..
:param:
**[in]** **context** - Library context
**[in]** **cksumtype** - Checksum type (0 for mandatory type)
**[in]** **key** - Encryption key for a keyed checksum
**[in]** **usage** - Key usage (see :data:`KRB5_KEYUSAGE` types)
**[in]** **input** - Input data
**[out]** **cksum** - Generated checksum
..
:retval:
- 0 Success; otherwise - Kerberos error codes
..
This function computes a checksum of type *cksumtype* over *input* , using *key* if the checksum type is a keyed checksum. If *cksumtype* is 0 and *key* is non-null, the checksum type will be the mandatory-to-implement checksum type for the key's encryption type. The actual checksum key will be derived from *key* and *usage* if key derivation is specified for the checksum type. The newly created *cksum* must be released by calling :c:func:`krb5_free_checksum_contents()` when it is no longer needed.
..
.. seealso::
:c:func:`krb5_c_verify_checksum()`
.. note::
This function is similar to :c:func:`krb5_k_make_checksum()` , but operates on keyblock *key* .
|