Package com.apress.prospring.ch6.security

Examples of com.apress.prospring.ch6.security.SecurityManager


    String propertyKey = SandeshaUtil.getSequencePropertyKey(rmMsgCtx);
   
    // Check that both the Sequence header and message body have been secured properly
    SequencePropertyBean tokenBean = seqPropMgr.retrieve(propertyKey, Sandesha2Constants.SequenceProperties.SECURITY_TOKEN);
    if(tokenBean != null) {
      SecurityManager secManager = SandeshaUtil.getSecurityManager(msgCtx.getConfigurationContext());
     
      QName seqName = new QName(rmMsgCtx.getRMNamespaceValue(), Sandesha2Constants.WSRM_COMMON.SEQUENCE);
     
      SOAPEnvelope envelope = msgCtx.getEnvelope();
      OMElement body = envelope.getBody();
      OMElement seqHeader = envelope.getHeader().getFirstChildWithName(seqName);
     
      SecurityToken token = secManager.recoverSecurityToken(tokenBean.getValue());
     
      secManager.checkProofOfPossession(token, seqHeader, msgCtx);
      secManager.checkProofOfPossession(token, body, msgCtx);
    }
   
    //RM will not send sync responses. If sync acks are there this will be
    // made true again later.
    if (rmMsgCtx.getMessageContext().getOperationContext() != null) {
View Full Code Here


          e.toString());
      log.debug(message,e);
    }
   
    configContext.setProperty(Sandesha2Constants.SECURITY_MANAGER,null);
    SecurityManager util = SandeshaUtil.getSecurityManager(configContext);
    util.initSecurity(module);

  }
View Full Code Here

//    if (pollingMode)
//      SandeshaUtil.startPollingManager(configCtx);
   
    SecurityToken token = (SecurityToken) createSeqRMMessage.getProperty(Sandesha2Constants.SequenceProperties.SECURITY_TOKEN);
    if(token != null) {
      SecurityManager secManager = SandeshaUtil.getSecurityManager(configCtx);
      rmsBean.setSecurityTokenData(secManager.getTokenRecoveryData(token));
     
      // If we are using token based security, and the 1.1 spec level, then we
      // should introduce a UsesSequenceSTR header into the message.
      if(createSequencePart.getNamespaceValue().equals(Sandesha2Constants.SPEC_2006_08.NS_URI)) {
        UsesSequenceSTR header = new UsesSequenceSTR(null, Sandesha2Constants.SPEC_2006_08.NS_URI);
View Full Code Here

TOP

Related Classes of com.apress.prospring.ch6.security.SecurityManager

Copyright © 2018 www.massapicom. 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.