[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
CVS shishi/lib
From: |
shishi-commit |
Subject: |
CVS shishi/lib |
Date: |
Fri, 17 Sep 2004 14:38:13 +0200 |
Update of /home/cvs/shishi/lib
In directory dopio:/tmp/cvs-serv21749
Modified Files:
shishi.h.in authenticator.c
Log Message:
(shishi_authenticator_cname_get):
(shishi_authenticator_cnamerealm_get): Remove.
(shishi_authenticator_client):
(shishi_authenticator_clientrealm): Add.
--- /home/cvs/shishi/lib/shishi.h.in 2004/09/17 12:31:03 1.245
+++ /home/cvs/shishi/lib/shishi.h.in 2004/09/17 12:38:12 1.246
@@ -889,13 +889,12 @@
extern int shishi_authenticator_seqnumber_set (Shishi * handle,
Shishi_asn1 authenticator,
uint32_t seqnumber);
-extern int shishi_authenticator_cname_get (Shishi * handle,
- Shishi_asn1 authenticator,
- char *cname, size_t * cnamelen);
-extern int shishi_authenticator_cnamerealm_get (Shishi * handle,
- Shishi_asn1 authenticator,
- char *cnamerealm,
- size_t * cnamerealmlen);
+extern int shishi_authenticator_client (Shishi * handle,
+ Shishi_asn1 authenticator,
+ char **client, size_t *clientlen);
+extern int shishi_authenticator_clientrealm (Shishi * handle,
+ Shishi_asn1 authenticator,
+ char **client, size_t *clientlen);
extern int shishi_authenticator_remove_cksum (Shishi * handle,
Shishi_asn1 authenticator);
extern int shishi_authenticator_cksum (Shishi * handle,
--- /home/cvs/shishi/lib/authenticator.c 2004/09/10 10:00:00 1.68
+++ /home/cvs/shishi/lib/authenticator.c 2004/09/17 12:38:12 1.69
@@ -536,25 +536,57 @@
return SHISHI_OK;
}
+/**
+ * shishi_authenticator_client:
+ * @handle: Shishi library handle create by shishi_init().
+ * @authenticator: Authenticator variable to get client name from.
+ * @client: pointer to newly allocated zero terminated string containing
+ * principal name. May be %NULL (to only populate @clientlen).
+ * @clientlen: pointer to length of @client on output, excluding terminating
+ * zero. May be %NULL (to only populate @client).
+ *
+ * Represent client principal name in Authenticator as zero-terminated
+ * string. The string is allocate by this function, and it is the
+ * responsibility of the caller to deallocate it. Note that the
+ * output length @clientlen does not include the terminating zero.
+ *
+ * Return value: Returns SHISHI_OK iff successful.
+ **/
int
-shishi_authenticator_cname_get (Shishi * handle,
- Shishi_asn1 authenticator,
- char *cname, size_t * cnamelen)
+shishi_authenticator_client (Shishi * handle,
+ Shishi_asn1 authenticator,
+ char **client, size_t *clientlen)
{
- return shishi_principal_name_get (handle, authenticator,
- "cname", cname, cnamelen);
+ return shishi_principal_name (handle, authenticator,
+ "cname", client, clientlen);
}
+/**
+ * shishi_authenticator_clientrealm:
+ * @handle: Shishi library handle create by shishi_init().
+ * @authenticator: Authenticator variable to get client name and realm from.
+ * @client: pointer to newly allocated zero terminated string containing
+ * principal name and realm. May be %NULL (to only populate @clientlen).
+ * @clientlen: pointer to length of @client on output, excluding terminating
+ * zero. May be %NULL (to only populate @client).
+ *
+ * Convert cname and realm fields from Authenticator to printable
+ * principal name format. The string is allocate by this function,
+ * and it is the responsibility of the caller to deallocate it. Note
+ * that the output length @clientlen does not include the terminating
+ * zero.
+ *
+ * Return value: Returns SHISHI_OK iff successful.
+ **/
int
-shishi_authenticator_cnamerealm_get (Shishi * handle,
- Shishi_asn1 authenticator,
- char *cnamerealm, size_t * cnamerealmlen)
+shishi_authenticator_clientrealm (Shishi * handle,
+ Shishi_asn1 authenticator,
+ char **client, size_t *clientlen)
{
- return shishi_principal_name_realm_get (handle, authenticator,
- "cname",
- authenticator,
- "crealm",
- cnamerealm, cnamerealmlen);
+ return shishi_principal_name_realm (handle,
+ authenticator, "cname",
+ authenticator, "crealm",
+ client, clientlen);
}
int
- CVS shishi/lib, (continued)
- CVS shishi/lib, shishi-commit, 2004/09/10
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib,
shishi-commit <=
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17
- CVS shishi/lib, shishi-commit, 2004/09/17