mirror of https://github.com/docker/docs.git
update signature proto to include sig algorithm
Signed-off-by: David Lawrence <david.lawrence@docker.com> (github: endophage)
This commit is contained in:
parent
65916d3fc4
commit
81d69a4f5c
|
@ -46,7 +46,8 @@ message PublicKey {
|
|||
// Signature specifies a KeyInfo that was used for signing and signed content
|
||||
message Signature {
|
||||
KeyInfo keyInfo = 1;
|
||||
bytes content = 2;
|
||||
Algorithm algorithm = 2;
|
||||
bytes content = 3;
|
||||
}
|
||||
|
||||
// SignatureRequests specifies a KeyInfo, and content to be signed
|
||||
|
|
|
@ -113,7 +113,8 @@ func (s *SignerServer) Sign(ctx context.Context, sr *pb.SignatureRequest) (*pb.S
|
|||
KeyID: &pb.KeyID{ID: tufKey.ID()},
|
||||
Algorithm: &pb.Algorithm{Algorithm: tufKey.Algorithm().String()},
|
||||
},
|
||||
Content: signatures[0].Signature,
|
||||
Algorithm: signatures[0].Method,
|
||||
Content: signatures[0].Signature,
|
||||
}
|
||||
|
||||
return signature, nil
|
||||
|
|
|
@ -54,7 +54,7 @@ func (trust *NotarySigner) Sign(keyIDs []string, toSign []byte) ([]data.Signatur
|
|||
}
|
||||
signatures = append(signatures, data.Signature{
|
||||
KeyID: sig.KeyInfo.KeyID.ID,
|
||||
Method: data.SigAlgorithm(sig.KeyInfo.Algorithm.Algorithm),
|
||||
Method: data.SigAlgorithm(sig.Algorithm.Algorithm),
|
||||
Signature: sig.Content,
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue