| 1 |
// Keep in sync with schema at https://slsa.dev/provenance/v0.2 |
| 2 |
syntax = "proto3"; |
| 3 |
|
| 4 |
package in_toto_attestation.predicates.provenance.v02; |
| 5 |
|
| 6 |
import "google/protobuf/struct.proto"; |
| 7 |
import "google/protobuf/timestamp.proto"; |
| 8 |
|
| 9 |
option go_package = "github.com/in-toto/attestation/go/predicates/provenance/v02"; |
| 10 |
option java_package = "io.github.intoto.attestation.predicates.provenance.v02"; |
| 11 |
|
| 12 |
// Proto representation of predicate type https://slsa.dev/provenance/v0.2 |
| 13 |
// Validation of all fields is left to the users of this proto. |
| 14 |
message Provenance { |
| 15 |
Builder builder = 1; |
| 16 |
string build_type = 2; |
| 17 |
Invocation invocation = 3; |
| 18 |
google.protobuf.Struct build_config = 4; |
| 19 |
Metadata metadata = 5; |
| 20 |
repeated Material materials = 6; |
| 21 |
} |
| 22 |
|
| 23 |
message Builder { |
| 24 |
string id = 1; |
| 25 |
} |
| 26 |
|
| 27 |
message Invocation { |
| 28 |
ConfigSource config_source = 1; |
| 29 |
google.protobuf.Struct parameters = 2; |
| 30 |
google.protobuf.Struct environment = 3; |
| 31 |
} |
| 32 |
|
| 33 |
message ConfigSource { |
| 34 |
string uri = 1; |
| 35 |
map<string, string> digest = 2; |
| 36 |
string entry_point = 3; |
| 37 |
} |
| 38 |
|
| 39 |
message Metadata { |
| 40 |
string build_invocation_id = 1; |
| 41 |
google.protobuf.Timestamp build_started_on = 2; |
| 42 |
google.protobuf.Timestamp build_finished_on = 3; |
| 43 |
Completeness completeness = 4; |
| 44 |
bool reproducible = 5; |
| 45 |
} |
| 46 |
|
| 47 |
message Completeness { |
| 48 |
bool parameters = 1; |
| 49 |
bool environment = 2; |
| 50 |
bool materials = 3; |
| 51 |
} |
| 52 |
|
| 53 |
message Material { |
| 54 |
string uri = 1; |
| 55 |
map<string, string> digest = 2; |
| 56 |
} |