auth/kerberos: Do a string comparison in kerberos_decode_pac() not a principal comparison
authorAndrew Bartlett <abartlet@samba.org>
Wed, 11 Mar 2015 02:57:06 +0000 (15:57 +1300)
committerGünther Deschner <gd@samba.org>
Thu, 12 Mar 2015 16:13:42 +0000 (17:13 +0100)
commite48d136e3a5c89c9bab8ea898775fad1449d2f96
tree0cc2412ba77511d4c70fe95d4d995ea3fb2355bd
parent89099611fd3a30286fe50dfa57e16452ea6c8940
auth/kerberos: Do a string comparison in kerberos_decode_pac() not a principal comparison

This ensures that if an enterprise principal is used, we do the
comparison properly

This matters as in the enterprise case, which can be triggered by MIT
kinit -E, does not use canonicalization, and so the enterprise name,
with the @ in it, is in the logon name.

Otherwise, we get errors like:
 Name in PAC [TESTALLOWED@WIN2012R2] does not match principal name in ticket

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11142

Signed-off-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
auth/kerberos/kerberos_pac.c