Skip to content

Conversation

@orien
Copy link
Contributor

@orien orien commented Jun 19, 2022

Context

Psych will interpret unquoted YAML values starting with a : character as a Ruby symbol. Symbol isn't listed as a permitted class when loading CloudFormation templates, so an error is raised.

This is an issue since YAML safe loading was introduced #98.

Change

Avoid raising an error in this scenario, add Symbol to the list of permitted classes when loading CloudFormation YAML templates.

Psych will interpret unquoted YAML values starting with a ':' character
as a Ruby symbol.

Avoid raising an error in this scenario, add Symbol to the list of
permitted classes when loading CloudFormation YAML templates.
@orien
Copy link
Contributor Author

orien commented Jun 19, 2022

@arothian: This should help with stelligent/cfn_nag#599

@arothian
Copy link
Contributor

Thanks @orien

@arothian arothian merged commit 0232e66 into stelligent:master Jun 23, 2022
@orien orien deleted the yaml-parsing-fix branch June 23, 2022 22:24
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.

2 participants