Examples of unseal()


Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

        newTicketBody.setClientPrincipal( tgt.getEncTicketPart().getClientPrincipal() );

        if ( request.getEncAuthorizationData() != null )
        {
            AuthorizationData authData = ( AuthorizationData ) cipherTextHandler.unseal( AuthorizationData.class,
                authenticator.getSubSessionKey(), request.getEncAuthorizationData(), KeyUsage.NUMBER4 );
            authData.add( tgt.getEncTicketPart().getAuthorizationData() );
            newTicketBody.setAuthorizationData( authData );
        }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

        EncKrbPrivPart privatePart;

        try
        {
            privatePart = ( EncKrbPrivPart ) cipherTextHandler.unseal( EncKrbPrivPart.class, subSessionKey,
                encReqPrivPart, KeyUsage.NUMBER13 );
        }
        catch ( KerberosException ke )
        {
            throw new ChangePasswordException( ErrorType.KRB5_KPASSWD_SOFTERROR, ke );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

                        catch ( ClassCastException cce )
                        {
                            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY, cce );
                        }

                        timestamp = ( EncryptedTimeStamp ) cipherTextHandler.unseal( EncryptedTimeStamp.class,
                            clientKey, dataValue, KeyUsage.NUMBER1 );
                    }
                }

                if ( preAuthData.length > 0 && timestamp == null )
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

            EncryptionKey encryptionKey =
                    new EncryptionKey(EncryptionType.getTypeByOrdinal(encryptionType), kerberosKey.getEncoded());

            CipherTextHandler cipherTextHandler = new CipherTextHandler();
            this.encTicketPart = (EncTicketPart) cipherTextHandler.unseal(
                    EncTicketPart.class, encryptionKey, applicationRequest.getTicket().getEncPart(), KeyUsage.NUMBER2);
        } catch (KerberosException e) {
            throw new KerberosTokenDecoderException(e);
        } catch (IOException e) {
            throw new KerberosTokenDecoderException(e);
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

            EncryptionKey encryptionKey =
                    new EncryptionKey(EncryptionType.getTypeByOrdinal(encryptionType), kerberosKey.getEncoded());

            CipherTextHandler cipherTextHandler = new CipherTextHandler();
            this.encTicketPart = (EncTicketPart) cipherTextHandler.unseal(
                    EncTicketPart.class, encryptionKey, applicationRequest.getTicket().getEncPart(), KeyUsage.NUMBER2);
        } catch (KerberosException e) {
            throw new KerberosTokenDecoderException(e);
        } catch (IOException e) {
            throw new KerberosTokenDecoderException(e);
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

        EncKrbPrivPart privatePart;

        try
        {
            privatePart = ( EncKrbPrivPart ) cipherTextHandler.unseal( EncKrbPrivPart.class, subSessionKey,
                encReqPrivPart, KeyUsage.KRB_PRIV_ENC_PART_CHOSEN_KEY );
        }
        catch ( KerberosException ke )
        {
            throw new ChangePasswordException( ErrorType.KRB5_KPASSWD_SOFTERROR, ke );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.crypto.encryption.CipherTextHandler.unseal()

            EncryptionKey encryptionKey =
                    new EncryptionKey(EncryptionType.getTypeByOrdinal(encryptionType), kerberosKey.getEncoded());

            CipherTextHandler cipherTextHandler = new CipherTextHandler();
            this.encTicketPart = (EncTicketPart) cipherTextHandler.unseal(
                    EncTicketPart.class, encryptionKey, applicationRequest.getTicket().getEncPart(), KeyUsage.NUMBER2);
        } catch (KerberosException e) {
            throw new KerberosTokenDecoderException(e);
        } catch (IOException e) {
            throw new KerberosTokenDecoderException(e);
View Full Code Here

Examples of org.switchyard.security.crypto.PrivateCrypto.unseal()

    }

    private Object sealUnseal(Serializable o) throws Exception {
        PrivateCrypto pc = new PrivateCrypto("TripleDES", 168);
        SealedObject so = pc.seal(o);
        o = pc.unseal(so);
        return o;
    }

}
View Full Code Here

Examples of org.switchyard.security.crypto.PrivateCrypto.unseal()

            } else if (object instanceof SealedObject) {
                PrivateCrypto privateCrypto = _systemSecurity.getPrivateCrypto();
                if (privateCrypto == null) {
                    throw new IllegalStateException("privateCrypto == null");
                }
                securityContext = (SecurityContext)privateCrypto.unseal((SealedObject)object);
            } else if (object != null) {
                throw new IllegalArgumentException(object.getClass().getName() + " != " + EXCHANGE_PROPERTY);
            }
        }
        UUID systemUUID = _systemSecurity.getUUID();
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.