Examples of PrincipalStore


Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

   
   
    private static void getServerEntry( AuthenticationContext authContext ) throws KerberosException, InvalidTicketException
    {
        KerberosPrincipal principal = authContext.getRequest().getServerPrincipal();
        PrincipalStore store = authContext.getStore();
   
        authContext.setServerEntry( getEntry( principal, store, ErrorType.KDC_ERR_S_PRINCIPAL_UNKNOWN ) );
    }   
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

   
   
    private static void getTicketPrincipalEntry( TicketGrantingContext tgsContext ) throws KerberosException
    {
        KerberosPrincipal principal = tgsContext.getTgt().getServerPrincipal();
        PrincipalStore store = tgsContext.getStore();

        PrincipalStoreEntry entry = KerberosUtils.getEntry( principal, store, ErrorType.KDC_ERR_S_PRINCIPAL_UNKNOWN );
        tgsContext.setTicketPrincipalEntry( entry );
    }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

   

    public static void getRequestPrincipalEntry( TicketGrantingContext tgsContext ) throws KerberosException
    {
        KerberosPrincipal principal = tgsContext.getRequest().getServerPrincipal();
        PrincipalStore store = tgsContext.getStore();

        PrincipalStoreEntry entry = KerberosUtils.getEntry( principal, store, ErrorType.KDC_ERR_S_PRINCIPAL_UNKNOWN );
        tgsContext.setRequestPrincipalEntry( entry );
    }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

    }
   
   
    private static void processPasswordChange( ChangePasswordContext changepwContext ) throws KerberosException
    {
        PrincipalStore store = changepwContext.getStore();
        Authenticator authenticator = changepwContext.getAuthenticator();
        String newPassword = changepwContext.getPassword();
        KerberosPrincipal clientPrincipal = authenticator.getClientPrincipal();

        // usec and seq-number must be present per MS but aren't in legacy kpasswd
        // seq-number must have same value as authenticator
        // ignore r-address

        try
        {
            String principalName = store.changePassword( clientPrincipal, newPassword );
            LOG.debug( "Successfully modified principal {}.", principalName );
        }
        catch ( NamingException ne )
        {
            throw new ChangePasswordException( ErrorType.KRB5_KPASSWD_SOFTERROR, ne.getExplanation().getBytes(), ne );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

   
   
    private static void getServerEntry( ChangePasswordContext changepwContext ) throws KerberosException
    {
        KerberosPrincipal principal =  changepwContext.getTicket().getServerPrincipal();
        PrincipalStore store = changepwContext.getStore();

        changepwContext.setServerEntry( KerberosUtils.getEntry( principal, store, org.apache.directory.server.kerberos.shared.exceptions.ErrorType.KDC_ERR_S_PRINCIPAL_UNKNOWN ) );
    }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

   
    private static void monitorContext( ChangePasswordContext changepwContext ) throws KerberosException
    {
        try
        {
            PrincipalStore store = changepwContext.getStore();
            ApplicationRequest authHeader = changepwContext.getAuthHeader();
            Ticket ticket = changepwContext.getTicket();
            ReplayCache replayCache = changepwContext.getReplayCache();
            long clockSkew = changepwContext.getConfig().getAllowableClockSkew();
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

    /**
     * @throws IOException if we cannot bind to the sockets
     */
    public void start() throws IOException, InvalidNameException
    {
        PrincipalStore store;

        // TODO - for now ignoring this catalog crap
        store = new DirectoryPrincipalStore( getDirectoryService(), new DN(this.getSearchBaseDn())  );
       
        if ( ( transports == null ) || ( transports.size() == 0 ) )
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

    /**
     * @throws IOException if we cannot bind to the specified ports
     */
    public void start() throws IOException, InvalidNameException
    {
        PrincipalStore store = new DirectoryPrincipalStore( getDirectoryService(), new DN(this.getSearchBaseDn())  );
       
        if ( ( transports == null ) || ( transports.size() == 0 ) )
        {
            // Default to UDP with port 464
            // We have to create a DatagramAcceptor
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

   
   
    private static void getTicketPrincipalEntry( TicketGrantingContext tgsContext ) throws KerberosException
    {
        PrincipalName principal = tgsContext.getTgt().getSName();
        PrincipalStore store = tgsContext.getStore();
       
        KerberosPrincipal principalWithRealm = KerberosUtils.getKerberosPrincipal( principal, tgsContext.getTgt().getRealm() );
        PrincipalStoreEntry entry = getEntry( principalWithRealm, store, ErrorType.KDC_ERR_S_PRINCIPAL_UNKNOWN );
        tgsContext.setTicketPrincipalEntry( entry );
    }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.store.PrincipalStore

    public static void getRequestPrincipalEntry( TicketGrantingContext tgsContext ) throws KerberosException
    {
        KerberosPrincipal principal = KerberosUtils.getKerberosPrincipal(
            tgsContext.getRequest().getKdcReqBody().getSName(), tgsContext.getRequest().getKdcReqBody().getRealm() );
        PrincipalStore store = tgsContext.getStore();

        PrincipalStoreEntry entry = getEntry( principal, store, ErrorType.KDC_ERR_S_PRINCIPAL_UNKNOWN );
        tgsContext.setRequestPrincipalEntry( entry );
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.