With the switch from gogo, the `oneof` fields no longer have their
`json:"name"` fields emitted. Protobuf doesn't formally support these
fields and tells users to use the `protojson` package, but we didn't and
the official format is incompatible with the current format we use.
This adds some custom marshaling code to the already existant custom
unmarshaling code to ensure these fields are marshaled with the correct
casing.
Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>
This modifies how build steps are unmarshaled from JSON into the
provenance attestation. The current method doesn't correctly handle
protobuf attributes that are used with `oneof`.
Signed-off-by: Jonathan A. Sternberg <jonathan.sternberg@docker.com>