krb5_wrap: Document smb_krb5_keyblock_init_contents()
authorAndreas Schneider <asn@samba.org>
Mon, 29 Aug 2016 09:21:07 +0000 (11:21 +0200)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 31 Aug 2016 18:59:15 +0000 (20:59 +0200)
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
lib/krb5_wrap/krb5_samba.c

index 189797f264a532aa26be18b2c3351f2819a61589..a28580b122196dc0b70b82285287b6d7948ae0dc 100644 (file)
@@ -1652,6 +1652,27 @@ krb5_error_code smb_krb5_get_credentials(krb5_context context,
        return ret;
 }
 
+/**
+ * @brief Initialize a krb5_keyblock with the given data.
+ *
+ * Initialized a new keyblock, allocates the contents fo the key and
+ * copies the data into the keyblock.
+ *
+ * @param[in]  context  The library context
+ *
+ * @param[in]  enctype  The encryption type.
+ *
+ * @param[in]  data     The date to initialize the keyblock with.
+ *
+ * @param[in]  length   The length of the keyblock.
+ *
+ * @param[in]  key      Newly allocated keyblock structure.
+ *
+ * The key date must be freed using krb5_free_keyblock_contents() when it is
+ * no longer needed.
+ *
+ * @return 0 on success, a Kerberos error code otherwise.
+ */
 krb5_error_code smb_krb5_keyblock_init_contents(krb5_context context,
                                                krb5_enctype enctype,
                                                const void *data,