forked from TrueCloudLab/frostfs-api-go
Fix issue with Sign/VerifyRequestHeader proto.Clone
proto.Clone couldn't makes copy for custom fields. We should reset and restore MetaHeader before/after Sign/Verify. Add test coverage to check that all works like expected.
This commit is contained in:
parent
24e5497b1d
commit
5c344bfceb
5 changed files with 185 additions and 45 deletions
|
@ -12,6 +12,7 @@ message TestRequest {
|
|||
int32 IntField = 1;
|
||||
string StringField = 2;
|
||||
bytes BytesField = 3;
|
||||
bytes CustomField = 4 [(gogoproto.customtype) = "testCustomField"];
|
||||
RequestMetaHeader Meta = 98 [(gogoproto.embed) = true, (gogoproto.nullable) = false];
|
||||
RequestVerificationHeader Header = 99 [(gogoproto.embed) = true, (gogoproto.nullable) = false];
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue