Package org.picketlink.identity.federation.saml.v2.assertion.SubjectType

Examples of org.picketlink.identity.federation.saml.v2.assertion.SubjectType.STSubType


            assertion.addStatement(authnStatement);
        }

        if (roles != null && !roles.isEmpty()) {
            AttributeStatementType attrStatement = StatementUtil.createAttributeStatementForRoles(roles, multiValuedRoles);
            assertion.addStatement(attrStatement);
        }

        // Add in the attributes information
        if (attributes != null && attributes.size() > 0) {
            AttributeStatementType attStatement = StatementUtil.createAttributeStatement(attributes);
            assertion.addStatement(attStatement);
        }

        try {
            samlResponseDocument = saml2Response.convert(responseType);
View Full Code Here


     * Create an empty attribute statement
     *
     * @return
     */
    public static AttributeStatementType createAttributeStatement() {
        return new AttributeStatementType();
    }
View Full Code Here

     *
     * @param attributeValue
     * @return
     */
    public static AttributeStatementType createAttributeStatement(String attributeValue) {
        AttributeStatementType attribStatement = new AttributeStatementType();
        AttributeType att = new AttributeType(attributeValue);
        att.addAttributeValue(attributeValue);

        attribStatement.addAttribute(new ASTChoiceType(att));
        return attribStatement;
    }
View Full Code Here

    public static AttributeStatementType createAttributeStatement(String attributeValue) {
        AttributeStatementType attribStatement = new AttributeStatementType();
        AttributeType att = new AttributeType(attributeValue);
        att.addAttributeValue(attributeValue);

        attribStatement.addAttribute(new ASTChoiceType(att));
        return attribStatement;
    }
View Full Code Here

     *
     * @param roleName
     * @return
     */
    public static AttributeType createAttributeForRole(String roleName) {
        AttributeType att = new AttributeType("role");
        att.setFriendlyName("role");
        att.setNameFormat(JBossSAMLURIConstants.ATTRIBUTE_FORMAT_BASIC.get());

        // rolename
        att.addAttributeValue(roleName);

        return att;
    }
View Full Code Here

     * @param attributeValue
     * @return
     */
    public static AttributeStatementType createAttributeStatement(String attributeValue) {
        AttributeStatementType attribStatement = new AttributeStatementType();
        AttributeType att = new AttributeType(attributeValue);
        att.addAttributeValue(attributeValue);

        attribStatement.addAttribute(new ASTChoiceType(att));
        return attribStatement;
    }
View Full Code Here

        if (!disableAuthnStatement) {
            String authContextRef = JBossSAMLURIConstants.AC_UNSPECIFIED.get();
            if (isNotNull(authMethod))
                authContextRef = authMethod;

            AuthnStatementType authnStatement = StatementUtil.createAuthnStatement(XMLTimeUtil.getIssueInstant(),
                    authContextRef);

            authnStatement.setSessionIndex(assertion.getID());

            assertion.addStatement(authnStatement);
        }

        if (roles != null && !roles.isEmpty()) {
View Full Code Here

        try {
            issueInstant = XMLTimeUtil.getIssueInstant();
        } catch (ConfigurationException e) {
            throw logger.processingError(e);
        }
        ConditionsType conditions = samlProtocolContext.getConditions();
        SubjectType subject = samlProtocolContext.getSubjectType();
        List<StatementAbstractType> statements = samlProtocolContext.getStatements();

        // generate an id for the new assertion.
        String assertionID = IDGenerator.create("ID_");
View Full Code Here

                response.addAssertion(new RTChoiceType((AssertionType) assertionParser.parse(xmlEventReader)));
            } else if (JBossSAMLConstants.STATUS.get().equals(elementName)) {
                response.setStatus(parseStatus(xmlEventReader));
            } else if (JBossSAMLConstants.ENCRYPTED_ASSERTION.get().equals(elementName)) {
                Element encryptedAssertion = StaxParserUtil.getDOMElement(xmlEventReader);
                response.addAssertion(new RTChoiceType(new EncryptedAssertionType(encryptedAssertion)));
            } else
                throw logger.parserUnknownTag(elementName, startElement.getLocation());
        }

        return response;
View Full Code Here

        if (statusCode == null)
            throw logger.issuerInfoMissingStatusCodeError();

        responseType.setStatus(createStatusType(statusCode));

        responseType.addAssertion(new RTChoiceType(new EncryptedAssertionType(encryptedAssertion)));
        return responseType;
    }
View Full Code Here

TOP

Related Classes of org.picketlink.identity.federation.saml.v2.assertion.SubjectType.STSubType

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.