}
private static void verifyServiceTicket( ChangePasswordContext changepwContext ) throws KerberosException
{
ChangePasswordConfig config = changepwContext.getConfig();
Ticket ticket = changepwContext.getTicket();
String primaryRealm = config.getPrimaryRealm();
KerberosPrincipal changepwPrincipal = config.getServicePrincipal();
KerberosPrincipal serverPrincipal = KerberosUtils.getKerberosPrincipal( ticket.getSName(), ticket.getRealm() );
// for some reason kpassword is setting the pricnipaltype value as 1 for ticket.getSName()
// hence changing to string based comparison for server and changepw principals
// instead of serverPrincipal.equals( changepwPrincipal )