aboutsummaryrefslogtreecommitdiff
path: root/src/include/krb5/krb5.hin
diff options
context:
space:
mode:
authorGreg Hudson <ghudson@mit.edu>2015-11-17 13:06:31 -0500
committerGreg Hudson <ghudson@mit.edu>2016-08-24 12:24:35 -0400
commitfaf9ad33e9e6b7ffaac02fcd249e60e2224f5ec7 (patch)
tree83991541f1e62981078f4034d8193955552b0e6e /src/include/krb5/krb5.hin
parent058a688335019709a9135f5c6377bb41f7eac5c9 (diff)
downloadkrb5-faf9ad33e9e6b7ffaac02fcd249e60e2224f5ec7.zip
krb5-faf9ad33e9e6b7ffaac02fcd249e60e2224f5ec7.tar.gz
krb5-faf9ad33e9e6b7ffaac02fcd249e60e2224f5ec7.tar.bz2
Add krb5_expand_hostname() API
Add a new public libkrb5 function expand_hostname(). It follows the same contract as the Heimdal function, except that the caller should use krb5_free_string() instead of krb5_xfree() to free the result. As a small side effect, we no longer remove trailing dots from the hostname in krb5_sname_to_principal() when invoked with type KRB5_NT_UNKNOWN. Adjust a test case in t_sn2princ.py accordingly. ticket: 8278 (new)
Diffstat (limited to 'src/include/krb5/krb5.hin')
-rw-r--r--src/include/krb5/krb5.hin17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/include/krb5/krb5.hin b/src/include/krb5/krb5.hin
index a1bf849..c8928cb 100644
--- a/src/include/krb5/krb5.hin
+++ b/src/include/krb5/krb5.hin
@@ -4968,6 +4968,23 @@ void KRB5_CALLCONV
krb5_free_default_realm(krb5_context context, char *lrealm);
/**
+ * Canonicalize a hostname, possibly using name service.
+ *
+ * @param [in] context Library context
+ * @param [in] host Input hostname
+ * @param [out] canonhost_out Canonicalized hostname
+ *
+ * This function canonicalizes orig_hostname, possibly using name service
+ * lookups if configuration permits. Use krb5_free_string() to free @a
+ * canonhost_out when it is no longer needed.
+ *
+ * @version New in 1.15
+ */
+krb5_error_code KRB5_CALLCONV
+krb5_expand_hostname(krb5_context context, const char *host,
+ char **canonhost_out);
+
+/**
* Generate a full principal name from a service name.
*
* @param [in] context Library context