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

Safe unmarshal #211

Merged
merged 1 commit into from
Oct 19, 2023
Merged

Safe unmarshal #211

merged 1 commit into from
Oct 19, 2023

Conversation

geir-waagboe
Copy link
Contributor

Hva har blitt lagt til✨🌈

Fikser kritisk sårbarhet fra code scanning: java/xxe

Se feks https://cheatsheetseries.owasp.org/cheatsheets/XML_External_Entity_Prevention_Cheat_Sheet.html

@geir-waagboe geir-waagboe requested a review from a team as a code owner October 17, 2023 14:22
fun Marshaller.toString(input: Any): String = StringWriter().use {
marshal(input, it)
it.toString()
}

fun safeUnmarshal(inputMessageText: String): XMLEIFellesformat {
// Disable XXE
Copy link
Contributor

@JMLindseth JMLindseth Oct 18, 2023

Choose a reason for hiding this comment

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

Kanskje det hadde vært fint å ta med hvorfor det disables også? 🤔 Eller så er det kanskje nok at det står i commiten 🤷‍♂️

@geir-waagboe geir-waagboe merged commit 98b5d31 into master Oct 19, 2023
5 checks passed
@geir-waagboe geir-waagboe deleted the safe-unmarshall branch October 19, 2023 10:22
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