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

Fix crash when evaluating nested sensitive values #1557

Merged
merged 1 commit into from Oct 22, 2022

Conversation

wata727
Copy link
Member

@wata727 wata727 commented Oct 22, 2022

As a limitation of go-cty, marked values cannot be serialized.
https://github.com/zclconf/go-cty/blob/v1.11.1/cty/msgpack/marshal.go#L45-L47

There are IsMarked/HasMark and ContainMarked methods for determining whether a value is marked, but the former cannot determine nested sensitive values such as objects. So returning a nested sensitive value will cause an error like #1457.

This PR fixes it to determine with ContainMarked when serializing the value.

@wata727 wata727 merged commit 84d1c1d into master Oct 22, 2022
@wata727 wata727 deleted the fix_crash_when_nested_sensitive_value branch October 22, 2022 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant