Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create Secure Parser for Unmarshalling SP File Content #3472

Merged
merged 2 commits into from
Apr 18, 2021

Conversation

hisanhunais
Copy link
Contributor

Proposed changes in this pull request

  • Creating a secure parser for Unmarshalling Service Provider File Content

Approach

  1. Introduced a secure SAXParserFactory
  2. Parsed the contained through the SAXParserFactor and generated a source object
  3. Perform unmarshall operation by passing the generated source object to the unmarshaller

Related PRs

https://github.com/wso2-support/carbon-identity-framework/pull/1550

@jenkins-is-staging
Copy link

PR builder started
Link: https://github.com/wso2/product-is/actions/runs/739956280

+ Constants.EXTERNAL_PARAMETER_ENTITIES_FEATURE + " or " + Constants.LOAD_EXTERNAL_DTD_FEATURE
+ " or secure-processing.");
}
//Creating source object using the secure parser
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
//Creating source object using the secure parser
// Creating source object using the secure parser.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed with 9dcda46

//Creating source object using the secure parser
Source xmlSource = new SAXSource(spf.newSAXParser().getXMLReader(),
new InputSource(new StringReader(spFileContent.getContent())));
//Performing unmarshall operation by passing the generated source object to the unmarshaller
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
//Performing unmarshall operation by passing the generated source object to the unmarshaller
// Performing unmarshall operation by passing the generated source object to the unmarshaller.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed with 9dcda46

@jenkins-is-staging
Copy link

PR builder completed
Link: https://github.com/wso2/product-is/actions/runs/739956280
Status: failure

@jenkins-is-staging
Copy link

PR builder started
Link: https://github.com/wso2/product-is/actions/runs/751178888

@jenkins-is-staging
Copy link

PR builder completed
Link: https://github.com/wso2/product-is/actions/runs/751178888
Status: failure

Copy link

@jenkins-is-staging jenkins-is-staging left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving the pull request based on the successful Jenkins job https://jenkins-support-all.wso2.com/jenkins/job/DEV_PR_BUILDER/1207/, started by ,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants