boolean useCrypto = false;
if (null != props.get(ESBEndpointConstants.USE_CRYPTO)) {
useCrypto = ((Boolean) props.get(ESBEndpointConstants.USE_CRYPTO)).booleanValue();
}
final EsbSecurity esbSecurity = EsbSecurity.fromString((String) props
.get(ESBEndpointConstants.ESB_SECURITY));
Policy policy = null;
if (EsbSecurity.TOKEN == esbSecurity) {
policy = policyProvider.getUsernamePolicy(bus);
} else if (EsbSecurity.SAML == esbSecurity) {