add some more krb5_c functions

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@12482 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2003-07-22 10:23:28 +00:00
parent 6d719817e4
commit aa10794d91
2 changed files with 65 additions and 1 deletions

View File

@@ -41,13 +41,17 @@
.Nm krb5_c_encrypt_length ,
.Nm krb5_c_enctype_compare ,
.Nm krb5_c_get_checksum ,
.Nm krb5_c_is_coll_proof_cksum ,
.Nm krb5_c_is_keyed_cksum ,
.Nm krb5_c_make_checksum ,
.Nm krb5_c_make_random_key ,
.Nm krb5_c_set_checksum ,
.Nm krb5_c_valid_cksumtype ,
.Nm krb5_c_valid_enctype ,
.Nm krb5_c_verify_checksum ,
.Nm krb5_copy_checksum ,
.Nm krb5_free_checksum ,
.Nm krb5_free_checksum_contents
.Nm krb5_free_checksum_contents ,
.Nd kerberos crypto API
.Sh LIBRARY
Kerberos 5 Library (libkrb5, -lkrb5)
@@ -152,6 +156,22 @@ Kerberos 5 Library (libkrb5, -lkrb5)
.Fa "krb5_cksumtype type"
.Fa "const krb5_data *data"
.Fc
.Ft krb5_boolean
.Fo krb5_c_valid_enctype
.Fa krb5_enctype etype"
.Fc
.Ft krb5_boolean
.Fo krb5_c_valid_cksumtype
.Fa "krb5_cksumtype ctype"
.Fc
.Ft krb5_boolean
.Fo krb5_c_is_coll_proof_cksum
.Fa "krb5_cksumtype ctype"
.Fc
.Ft krb5_boolean
.Fo krb5_c_is_keyed_cksum
.Fa "krb5_cksumtype ctype"
.Fc
.Sh DESCRIPTION
The
.Li krb5_checksum
@@ -269,6 +289,26 @@ or
is not needed for the application,
.Dv NULL
can be passed in.
.Pp
.Fn krb5_c_valid_enctype
returns true if
.Fa etype
is a valid encryption type.
.Pp
.Fn krb5_c_valid_cksumtype
returns true if
.Fa ctype
is a valid checksum type.
.Pp
.Fn krb5_c_is_keyed_cksum
return true if
.Fa ctype
is a keyed checksum type.
.Pp
.Fn krb5_c_is_coll_proof_cksum
returns true if
.Fa ctype
is a collition proof checksum type.
.Sh SEE ALSO
.Xr krb5 3 ,
.Xr krb5_free_data 3 ,

View File

@@ -135,6 +135,30 @@ krb5_checksum_free(krb5_context context, krb5_checksum *cksum)
free_Checksum(cksum);
}
krb5_boolean
krb5_c_valid_enctype (krb5_enctype etype)
{
return krb5_enctype_valid(NULL, etype);
}
krb5_boolean
krb5_c_valid_cksumtype(krb5_cksumtype ctype)
{
return krb5_cksumtype_valid(NULL, ctype);
}
krb5_boolean
krb5_c_is_coll_proof_cksum(krb5_cksumtype ctype)
{
return krb5_checksum_is_collision_proof(NULL, ctype);
}
krb5_boolean
krb5_c_is_keyed_cksum(krb5_cksumtype ctype)
{
return krb5_checksum_is_keyed(NULL, ctype);
}
krb5_error_code
krb5_copy_checksum (krb5_context context,
const krb5_checksum *old,