summaryrefslogtreecommitdiffstats
path: root/src/include/krb5
diff options
context:
space:
mode:
authorGreg Hudson <ghudson@mit.edu>2012-05-10 17:34:10 +0000
committerGreg Hudson <ghudson@mit.edu>2012-05-10 17:34:10 +0000
commit0eb4672034bc48c94f0ab4775b114d5b8b89e696 (patch)
treefac6369a4f8c2319d21fb925c1be002b26297840 /src/include/krb5
parentf609e5caff410cc8f71db7d95b4da219541437db (diff)
downloadkrb5-0eb4672034bc48c94f0ab4775b114d5b8b89e696.tar.gz
krb5-0eb4672034bc48c94f0ab4775b114d5b8b89e696.tar.xz
krb5-0eb4672034bc48c94f0ab4775b114d5b8b89e696.zip
Add krb5_parse_name flag to ignore realm
The flag KRB5_PRINCIPAL_PARSE_IGNORE_REALM causes krb5_parse_name to return the principal with an empty realm whether or not a realm is present in the name. ticket: 7129 git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25862 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/include/krb5')
-rw-r--r--src/include/krb5/krb5.hin7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/include/krb5/krb5.hin b/src/include/krb5/krb5.hin
index 284e6b327..3208be54c 100644
--- a/src/include/krb5/krb5.hin
+++ b/src/include/krb5/krb5.hin
@@ -3409,6 +3409,7 @@ krb5_parse_name(krb5_context context, const char *name,
#define KRB5_PRINCIPAL_PARSE_REQUIRE_REALM 0x2 /**< Error if realm is not present */
#define KRB5_PRINCIPAL_PARSE_ENTERPRISE 0x4 /**< Create single-component
enterprise principle */
+#define KRB5_PRINCIPAL_PARSE_IGNORE_REALM 0x8 /**< Ignore realm if present */
/**
* Convert a string principal name to a krb5_principal with flags.
@@ -3426,6 +3427,12 @@ krb5_parse_name(krb5_context context, const char *name,
* @li #KRB5_PRINCIPAL_PARSE_REQUIRE_REALM - realm must be present in @a name
* @li #KRB5_PRINCIPAL_PARSE_ENTERPRISE - create single-component enterprise
* principal
+ * @li #KRB5_PRINCIPAL_PARSE_IGNORE_REALM - ignore realm if present in @a name
+ *
+ * If @c KRB5_PRINCIPAL_PARSE_NO_REALM or @c KRB5_PRINCIPAL_PARSE_IGNORE_REALM
+ * is specified in @a flags, the realm of the new principal will be empty.
+ * Otherwise, the default realm for @a context will be used if @a name does not
+ * specify a realm.
*
* Use krb5_free_principal() to free @a principal_out when it is no longer
* needed.