add krb5_cc_get_prefix_ops
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@13702 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -480,3 +480,20 @@ krb5_cc_clear_mcred(krb5_creds *mcred)
|
||||
{
|
||||
memset(mcred, 0, sizeof(*mcred));
|
||||
}
|
||||
|
||||
/*
|
||||
* Get the cc ops that is registered in `context' to handle the
|
||||
* `prefix'. Returns NULL if ops not found.
|
||||
*/
|
||||
|
||||
const krb5_cc_ops *
|
||||
krb5_cc_get_prefix_ops(krb5_context context, const char *prefix)
|
||||
{
|
||||
int i;
|
||||
|
||||
for(i = 0; i < context->num_cc_ops && context->cc_ops[i].prefix; i++) {
|
||||
if(strcmp(context->cc_ops[i].prefix, prefix) == 0)
|
||||
return &context->cc_ops[i];
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
@@ -31,7 +31,7 @@
|
||||
.\"
|
||||
.\" $Id$
|
||||
.\"
|
||||
.Dd March 16, 2003
|
||||
.Dd April 13, 2004
|
||||
.Dt KRB5_CCACHE 3
|
||||
.Os HEIMDAL
|
||||
.Sh NAME
|
||||
@@ -49,19 +49,20 @@
|
||||
.Nm krb5_cc_end_seq_get ,
|
||||
.Nm krb5_cc_gen_new ,
|
||||
.Nm krb5_cc_get_name ,
|
||||
.Nm krb5_cc_get_ops ,
|
||||
.Nm krb5_cc_get_prefix_ops ,
|
||||
.Nm krb5_cc_get_principal ,
|
||||
.Nm krb5_cc_get_type ,
|
||||
.Nm krb5_cc_get_ops ,
|
||||
.Nm krb5_cc_get_version ,
|
||||
.Nm krb5_cc_initialize ,
|
||||
.Nm krb5_cc_next_cred
|
||||
.Nm krb5_cc_register ,
|
||||
.Nm krb5_cc_remove_cred ,
|
||||
.Nm krb5_cc_resolve ,
|
||||
.Nm krb5_cc_retrieve_cred ,
|
||||
.Nm krb5_cc_remove_cred ,
|
||||
.Nm krb5_cc_set_default_name ,
|
||||
.Nm krb5_cc_store_cred ,
|
||||
.Nm krb5_cc_set_flags ,
|
||||
.Nm krb5_cc_next_cred
|
||||
.Nm krb5_cc_store_cred ,
|
||||
.Nd mange credential cache
|
||||
.Sh LIBRARY
|
||||
Kerberos 5 Library (libkrb5, -lkrb5)
|
||||
@@ -140,6 +141,11 @@ Kerberos 5 Library (libkrb5, -lkrb5)
|
||||
.Fa "krb5_context *context"
|
||||
.Fa "krb5_ccache id"
|
||||
.Fc
|
||||
.Ft "const krb5_cc_ops *"
|
||||
.Fo krb5_cc_get_prefix_ops
|
||||
.Fa "krb5_context context"
|
||||
.Fa "const char *prefix"
|
||||
.Fc
|
||||
.Ft krb5_error_code
|
||||
.Fo krb5_cc_get_version
|
||||
.Fa "krb5_context *context"
|
||||
@@ -315,6 +321,15 @@ overwriting any existing one if
|
||||
.Fa override .
|
||||
Return an error code or 0.
|
||||
.Pp
|
||||
.Fn krb5_cc_get_prefix_ops
|
||||
Get the cc ops that is registered in
|
||||
.Fa context
|
||||
to handle the
|
||||
.Fa prefix .
|
||||
Returns
|
||||
.Dv NULL
|
||||
if ops not found.
|
||||
.Pp
|
||||
.Fn krb5_cc_remove_cred
|
||||
removes the credential identified by
|
||||
.Fa ( cred ,
|
||||
|
Reference in New Issue
Block a user