Examples of PrivateMessage


Examples of com.tmm.enterprise.microblog.domain.PrivateMessage

      recipient = contactService.loadPerson(id);
    } catch (Exception e) {
      throw new ButterflyException(ButterflyExceptionCode.USER002_INVALIDUSERID, "Invalid recipient ID provided - ID must be numeric", e);
    }

    PrivateMessage pm = new PrivateMessage();
    pm.setDetails(msg);
    pm.setAssignedTo(recipient);
    pm.setRaisedBy(sender);

    createPrivateMessage(pm);
    sender.addSentMessage(pm);
    recipient.addReceivedMessage(pm);
  }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        catch ( KerberosException ke )
        {
            throw new ChangePasswordException( ErrorType.KRB5_KPASSWD_SOFTERROR, ke );
        }

        PrivateMessage privateMessage = new PrivateMessage( encPrivPart );

        // Begin AP_REP generation
        EncApRepPartModifier encApModifier = new EncApRepPartModifier();
        encApModifier.setClientTime( authenticator.getClientTime() );
        encApModifier.setClientMicroSecond( authenticator.getClientMicroSecond() );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

    {
        try
        {
            ChangePasswordReply reply = ( ChangePasswordReply ) changepwContext.getReply();
            ApplicationReply appReply = reply.getApplicationReply();
            PrivateMessage priv = reply.getPrivateMessage();

            StringBuilder sb = new StringBuilder();
            sb.append( "Responding with change password reply:" );
            sb.append( "\n\t" + "appReply               " + appReply );
            sb.append( "\n\t" + "priv                   " + priv );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

    }


    private PrivateMessage decodePrivateMessageSequence( DERSequence sequence )
    {
        PrivateMessage message = new PrivateMessage();

        for ( Enumeration<DEREncodable> e = sequence.getObjects(); e.hasMoreElements(); )
        {
            DERTaggedObject object = ( DERTaggedObject ) e.nextElement();
            int tag = object.getTagNo();
            DEREncodable derObject = object.getObject();

            switch ( tag )
            {
                case 0:
                    DERInteger tag0 = ( DERInteger ) derObject;
                    message.setProtocolVersionNumber( tag0.intValue() );
                    break;
                   
                case 1:
                    DERInteger tag1 = ( DERInteger ) derObject;
                    message.setMessageType( KerberosMessageType.getTypeByOrdinal( tag1.intValue() ) );
                    break;
                   
                case 3:
                    DERSequence tag3 = ( DERSequence ) derObject;
                    message.setEncryptedPart( EncryptedDataDecoder.decode( tag3 ) );
                    break;
            }
        }

        return message;
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        ApplicationRequest appRequest = message.getAuthHeader();
        ApplicationRequestEncoder appEncoder = new ApplicationRequestEncoder();
        byte[] encodedAppRequest = appEncoder.encode( appRequest );

        // Build private message bytes
        PrivateMessage privateMessage = message.getPrivateMessage();
        PrivateMessageEncoder privateEncoder = new PrivateMessageEncoder();
        byte[] privateBytes = privateEncoder.encode( privateMessage );

        short messageLength = ( short ) ( HEADER_LENGTH + encodedAppRequest.length + privateBytes.length );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        int privateBytesLength = messageLength - HEADER_LENGTH - encodedAppReplyLength;
        byte[] encodedPrivateMessage = new byte[privateBytesLength];
        buf.get( encodedPrivateMessage );

        PrivateMessageDecoder privateDecoder = new PrivateMessageDecoder();
        PrivateMessage privateMessage = privateDecoder.decode( encodedPrivateMessage );
        modifier.setPrivateMessage( privateMessage );

        return modifier.getChangePasswordReply();
    }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        byte[] encodedPrivate = new byte[buf.remaining()];
        buf.get( encodedPrivate, 0, buf.remaining() );

        PrivateMessageDecoder privateDecoder = new PrivateMessageDecoder();
        PrivateMessage privMessage = privateDecoder.decode( encodedPrivate );

        modifier.setPrivateMessage( privMessage );

        return modifier.getChangePasswordMessage();
    }
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        ApplicationReply appReply = message.getApplicationReply();
        ApplicationReplyEncoder appEncoder = new ApplicationReplyEncoder();
        byte[] encodedAppReply = appEncoder.encode( appReply );

        // Build private message bytes
        PrivateMessage privateMessage = message.getPrivateMessage();
        PrivateMessageEncoder privateEncoder = new PrivateMessageEncoder();
        byte[] privateBytes = privateEncoder.encode( privateMessage );

        short messageLength = ( short ) ( HEADER_LENGTH + encodedAppReply.length + privateBytes.length );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        ApplicationRequest apReq = new ApplicationRequest( apOptions, serviceTicket, encryptedAuthenticator );

        String newPassword = "secretsecret";

        PrivateMessage priv = getChangePasswordPrivateMessage( newPassword, subSessionKey );

        ChangePasswordRequest message = new ChangePasswordRequest( ( short ) 1, apReq, priv );

        handler.messageReceived( session, message );
View Full Code Here

Examples of org.apache.directory.server.kerberos.shared.messages.application.PrivateMessage

        ApplicationRequest apReq = new ApplicationRequest( apOptions, serviceTicket, encryptedAuthenticator );

        String newPassword = "secretsecret";

        PrivateMessage priv = getSetPasswordPrivateMessage( newPassword, subSessionKey, getPrincipalName( "hnelson" ) );

        ChangePasswordRequest message = new ChangePasswordRequest( ( short ) 0xFF80, apReq, priv );

        handler.messageReceived( session, message );
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.