proto3 compiler doesn't like required/optional anymore?
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Jeffrey Paul 2022-02-01 23:48:42 -08:00
parent 7b869592ce
commit b9c51fdeeb

View File

@ -11,12 +11,12 @@ message MFFile {
} }
// required mffile root attributes 1xx // required mffile root attributes 1xx
required Version version = 101; Version version = 101;
required bytes innerMessage = 102; bytes innerMessage = 102;
// these are used solely to detect corruption/truncation // these are used solely to detect corruption/truncation
// and not for cryptographic integrity. // and not for cryptographic integrity.
required uint64 size = 103; uint64 size = 103;
required bytes sha256 = 104; bytes sha256 = 104;
// 2xx for optional manifest root attributes // 2xx for optional manifest root attributes
// think we might use gosignify instead of gpg: // think we might use gosignify instead of gpg:
@ -32,8 +32,8 @@ message MFFile {
message MFFilePath { message MFFilePath {
// required attributes: // required attributes:
required string path = 101; string path = 101;
required uint64 size = 102; uint64 size = 102;
// gotta have at least one: // gotta have at least one:
repeated MFFileChecksum hashes = 201; repeated MFFileChecksum hashes = 201;
@ -49,7 +49,7 @@ message MFFilePath {
message MFFileChecksum { message MFFileChecksum {
// 1.0 golang implementation must write a multihash here // 1.0 golang implementation must write a multihash here
// it's ok to only ever use/verify sha256 multihash // it's ok to only ever use/verify sha256 multihash
required bytes multiHash = 1; bytes multiHash = 1;
} }
message MFFileInner { message MFFileInner {
@ -57,10 +57,10 @@ message MFFileInner {
NONE = 0; NONE = 0;
ONE = 1; // only one for now ONE = 1; // only one for now
} }
required Version version = 101; Version version = 101;
// required manifest attributes: // required manifest attributes:
required uint64 fileCount = 102; //FIXME is this necessary? uint64 fileCount = 102; //FIXME is this necessary?
repeated MFFilePath files = 103; repeated MFFilePath files = 103;
// optional manifest attributes 2xx: // optional manifest attributes 2xx: