krb5_sname_to_principal gets the hostname if we tell is host = NULL.
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23674 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -111,12 +111,7 @@ import_hostbased_name (OM_uint32 *minor_status,
|
|||||||
*p = '\0';
|
*p = '\0';
|
||||||
host = p + 1;
|
host = p + 1;
|
||||||
} else {
|
} else {
|
||||||
if (gethostname(local_hostname, sizeof(local_hostname)) < 0) {
|
host = NULL;
|
||||||
*minor_status = errno;
|
|
||||||
free (tmp);
|
|
||||||
return GSS_S_FAILURE;
|
|
||||||
}
|
|
||||||
host = local_hostname;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
kerr = krb5_sname_to_principal (context,
|
kerr = krb5_sname_to_principal (context,
|
||||||
|
Reference in New Issue
Block a user