Skip to content

Fix templates with policies with Go 1.24#744

Merged
maraino merged 2 commits intomasterfrom
mariano/policies
Apr 15, 2025
Merged

Fix templates with policies with Go 1.24#744
maraino merged 2 commits intomasterfrom
mariano/policies

Conversation

@maraino
Copy link
Copy Markdown
Contributor

@maraino maraino commented Apr 1, 2025

Description

This commit fixes templates with policy identifiers on a program with the go.mod set to 1.24. With Go 1.24, the policies extension is marshaled using the values in the Policies field, but with Go 1.23 or a previous version, the marshaled field is PolicyIdentifiers.

This commit sets the same values on Policies and PolicyIdentifiers, ensuring that the templates with policies work in different versions of Go.

Fixes #738

This commit fixes templates with policy identifiers on a program
with the go.mod set to 1.24. With Go 1.24, the policies extension is
marshaled using the values in the Policies field, but with Go 1.23 or
a previous version, the marshaled field is PolicyIdentifiers.

This commit sets the same values on Policies and PolicyIdentifiers,
ensuring that the templates with policies work in different versions
of Go.

Fixes #738
@maraino maraino requested a review from hslatman April 1, 2025 23:58
Comment thread x509util/marshal_utils.go
@maraino maraino merged commit 7b69ae9 into master Apr 15, 2025
12 checks passed
@maraino maraino deleted the mariano/policies branch April 15, 2025 19:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update x509util.Certificate to manage policies

3 participants