}
service = principals.iterator().next().getName();
}
// Validate the ticket
KerberosServiceExceptionAction action = new KerberosServiceExceptionAction(token, service, isUsernameServiceNameForm());
KerberosServiceContext krbServiceCtx = null;
try {
krbServiceCtx = (KerberosServiceContext)Subject.doAs(subject, action);
} catch (PrivilegedActionException e) {
Throwable cause = e.getCause();