/** * Given a set of roles, create an attribute statement * * @param roles * @return */ private SAML11AttributeStatementType createAttributeStatement(List<String> roles) { SAML11AttributeStatementType attrStatement = null; for (String role : roles) { if (attrStatement == null) { attrStatement = new SAML11AttributeStatementType(); } SAML11AttributeType attr = new SAML11AttributeType("Role", URI.create("urn:picketlink:role")); attr.add(role); attrStatement.add(attr); } return attrStatement; }
throws ParsingException SAML11AttributeStatementType attributeStatementType = new SAML11AttributeStatementType(); attributeStatementType.add(attribute); attributeStatementType.setSubject(subject);
public void write(SAML11AttributeStatementType statement) throws ProcessingException { StaxUtil.writeStartElement(writer, ASSERTION_PREFIX, JBossSAMLConstants.ATTRIBUTE_STATEMENT.get(), SAML11Constants.ASSERTION_11_NSURI); SAML11SubjectType subject = statement.getSubject(); if (subject != null) write(subject); List<SAML11AttributeType> attributes = statement.get(); if (attributes != null) { for (SAML11AttributeType attr : attributes) { write(attr); } } StaxUtil.writeEndElement(writer); StaxUtil.flush(writer); }
List<SAML11AttributeType> attributes = attributeStatement.get(); for (SAML11AttributeType attr : attributes)
throws ParsingException SAML11AttributeStatementType attributeStatementType = new SAML11AttributeStatementType(); attributeStatementType.add(attribute); attributeStatementType.setSubject(subject);
public void write(SAML11AttributeStatementType statement) throws ProcessingException { StaxUtil.writeStartElement(writer, ASSERTION_PREFIX, JBossSAMLConstants.ATTRIBUTE_STATEMENT.get(), SAML11Constants.ASSERTION_11_NSURI); SAML11SubjectType subject = statement.getSubject(); if (subject != null) write(subject); List<SAML11AttributeType> attributes = statement.get(); if (attributes != null) { for (SAML11AttributeType attr : attributes) { write(attr); } } StaxUtil.writeEndElement(writer); StaxUtil.flush(writer); }
List<SAML11AttributeType> attributes = attributeStatement.get(); for (SAML11AttributeType attr : attributes)
SAML11AttributeStatementType attributeStatementType = new SAML11AttributeStatementType(); if (JBossSAMLConstants.ATTRIBUTE.get().equals(tag)) { SAML11AttributeType attribute = parseSAML11Attribute(xmlEventReader); attributeStatementType.add(attribute); } else if (JBossSAMLConstants.SUBJECT.get().equals(tag)) { SAML11SubjectParser parser = new SAML11SubjectParser(); SAML11SubjectType subject = (SAML11SubjectType) parser.parse(xmlEventReader); attributeStatementType.setSubject(subject); } else throw logger.parserUnknownTag(tag, startElement.getLocation());
/** * Given a set of roles, create an attribute statement * * @param roles * @return */ private SAML11AttributeStatementType createAttributeStatement(List<String> roles) { SAML11AttributeStatementType attrStatement = null; for (String role : roles) { if (attrStatement == null) { attrStatement = new SAML11AttributeStatementType(); } SAML11AttributeType attr = new SAML11AttributeType("Role", URI.create("urn:picketlink:role")); attr.add(role); attrStatement.add(attr); } return attrStatement; }
public void write(SAML11AttributeStatementType statement) throws ProcessingException { StaxUtil.writeStartElement(writer, ASSERTION_PREFIX, JBossSAMLConstants.ATTRIBUTE_STATEMENT.get(), SAML11Constants.ASSERTION_11_NSURI); SAML11SubjectType subject = statement.getSubject(); if (subject != null) write(subject); List<SAML11AttributeType> attributes = statement.get(); if (attributes != null) { for (SAML11AttributeType attr : attributes) { write(attr); } } StaxUtil.writeEndElement(writer); StaxUtil.flush(writer); }
if (statement instanceof SAML11AttributeStatementType) { SAML11AttributeStatementType attributeStatement = (SAML11AttributeStatementType) statement; List<SAML11AttributeType> attributes = attributeStatement.get(); for (SAML11AttributeType attr : attributes) { if (roleKeys != null && roleKeys.size() > 0) {
SAML11AttributeStatementType attributeStatementType = new SAML11AttributeStatementType(); if (JBossSAMLConstants.ATTRIBUTE.get().equals(tag)) { SAML11AttributeType attribute = parseSAML11Attribute(xmlEventReader); attributeStatementType.add(attribute); } else if (JBossSAMLConstants.SUBJECT.get().equals(tag)) { SAML11SubjectParser parser = new SAML11SubjectParser(); SAML11SubjectType subject = (SAML11SubjectType) parser.parse(xmlEventReader); attributeStatementType.setSubject(subject); } else throw logger.parserUnknownTag(tag, startElement.getLocation());
/** * Given a set of roles, create an attribute statement * * @param roles * @return */ private SAML11AttributeStatementType createAttributeStatement(List<String> roles) { SAML11AttributeStatementType attrStatement = null; for (String role : roles) { if (attrStatement == null) { attrStatement = new SAML11AttributeStatementType(); } SAML11AttributeType attr = new SAML11AttributeType("Role", URI.create("urn:picketlink:role")); //$NON-NLS-1$ //$NON-NLS-2$ attr.add(role); attrStatement.add(attr); } return attrStatement; }
public void write(SAML11AttributeStatementType statement) throws ProcessingException { StaxUtil.writeStartElement(writer, ASSERTION_PREFIX, JBossSAMLConstants.ATTRIBUTE_STATEMENT.get(), SAML11Constants.ASSERTION_11_NSURI); SAML11SubjectType subject = statement.getSubject(); if (subject != null) write(subject); List<SAML11AttributeType> attributes = statement.get(); if (attributes != null) { for (SAML11AttributeType attr : attributes) { write(attr); } } StaxUtil.writeEndElement(writer); StaxUtil.flush(writer); }
if (statement instanceof SAML11AttributeStatementType) { SAML11AttributeStatementType attributeStatement = (SAML11AttributeStatementType) statement; List<SAML11AttributeType> attributes = attributeStatement.get(); for (SAML11AttributeType attr : attributes) { if (roleKeys != null && roleKeys.size() > 0) {
SAML11AttributeStatementType attributeStatementType = new SAML11AttributeStatementType(); if (JBossSAMLConstants.ATTRIBUTE.get().equals(tag)) { SAML11AttributeType attribute = parseSAML11Attribute(xmlEventReader); attributeStatementType.add(attribute); } else if (JBossSAMLConstants.SUBJECT.get().equals(tag)) { SAML11SubjectParser parser = new SAML11SubjectParser(); SAML11SubjectType subject = (SAML11SubjectType) parser.parse(xmlEventReader); attributeStatementType.setSubject(subject); } else throw logger.parserUnknownTag(tag, startElement.getLocation());
/** * Given a set of roles, create an attribute statement * * @param roles * * @return */ private SAML11AttributeStatementType createAttributeStatement(List<String> roles) { SAML11AttributeStatementType attrStatement = null; for (String role : roles) { if (attrStatement == null) { attrStatement = new SAML11AttributeStatementType(); } SAML11AttributeType attr = new SAML11AttributeType("Role", URI.create("urn:picketlink:role")); attr.add(role); attrStatement.add(attr); } return attrStatement; }
public void write(SAML11AttributeStatementType statement) throws ProcessingException { StaxUtil.writeStartElement(writer, ASSERTION_PREFIX, JBossSAMLConstants.ATTRIBUTE_STATEMENT.get(), SAML11Constants.ASSERTION_11_NSURI); SAML11SubjectType subject = statement.getSubject(); if (subject != null) write(subject); List<SAML11AttributeType> attributes = statement.get(); if (attributes != null) { for (SAML11AttributeType attr : attributes) { write(attr); } } StaxUtil.writeEndElement(writer); StaxUtil.flush(writer); }
if (statement instanceof SAML11AttributeStatementType) { SAML11AttributeStatementType attributeStatement = (SAML11AttributeStatementType) statement; List<SAML11AttributeType> attributes = attributeStatement.get(); for (SAML11AttributeType attr : attributes) { if (roleKeys != null && roleKeys.size() > 0) {
/** * Given a set of roles, create an attribute statement * * @param roles * * @return */ private SAML11AttributeStatementType createAttributeStatement(List<String> roles) { SAML11AttributeStatementType attrStatement = null; for (String role : roles) { if (attrStatement == null) { attrStatement = new SAML11AttributeStatementType(); } SAML11AttributeType attr = new SAML11AttributeType("Role", URI.create("urn:picketlink:role")); attr.add(role); attrStatement.add(attr); } return attrStatement; }