grafeas-v1 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. checksums.yaml +7 -0
  2. data/.yardopts +11 -0
  3. data/LICENSE.md +203 -0
  4. data/README.md +63 -0
  5. data/lib/grafeas-v1.rb +21 -0
  6. data/lib/grafeas/v1.rb +31 -0
  7. data/lib/grafeas/v1/attestation_pb.rb +28 -0
  8. data/lib/grafeas/v1/build_pb.rb +24 -0
  9. data/lib/grafeas/v1/common_pb.rb +36 -0
  10. data/lib/grafeas/v1/cvss_pb.rb +68 -0
  11. data/lib/grafeas/v1/deployment_pb.rb +36 -0
  12. data/lib/grafeas/v1/discovery_pb.rb +44 -0
  13. data/lib/grafeas/v1/grafeas.rb +57 -0
  14. data/lib/grafeas/v1/grafeas/client.rb +1459 -0
  15. data/lib/grafeas/v1/grafeas/paths.rb +77 -0
  16. data/lib/grafeas/v1/grafeas_pb.rb +169 -0
  17. data/lib/grafeas/v1/grafeas_services_pb.rb +85 -0
  18. data/lib/grafeas/v1/image_pb.rb +37 -0
  19. data/lib/grafeas/v1/package_pb.rb +60 -0
  20. data/lib/grafeas/v1/provenance_pb.rb +117 -0
  21. data/lib/grafeas/v1/upgrade_pb.rb +57 -0
  22. data/lib/grafeas/v1/version.rb +24 -0
  23. data/lib/grafeas/v1/vulnerability_pb.rb +85 -0
  24. data/proto_docs/README.md +4 -0
  25. data/proto_docs/google/api/field_behavior.rb +59 -0
  26. data/proto_docs/google/api/resource.rb +247 -0
  27. data/proto_docs/google/protobuf/any.rb +138 -0
  28. data/proto_docs/google/protobuf/empty.rb +36 -0
  29. data/proto_docs/google/protobuf/field_mask.rb +229 -0
  30. data/proto_docs/google/protobuf/timestamp.rb +120 -0
  31. data/proto_docs/google/rpc/status.rb +46 -0
  32. data/proto_docs/grafeas/v1/attestation.rb +77 -0
  33. data/proto_docs/grafeas/v1/build.rb +54 -0
  34. data/proto_docs/grafeas/v1/common.rb +118 -0
  35. data/proto_docs/grafeas/v1/cvss.rb +111 -0
  36. data/proto_docs/grafeas/v1/deployment.rb +74 -0
  37. data/proto_docs/grafeas/v1/discovery.rb +92 -0
  38. data/proto_docs/grafeas/v1/grafeas.rb +404 -0
  39. data/proto_docs/grafeas/v1/image.rb +95 -0
  40. data/proto_docs/grafeas/v1/package.rb +144 -0
  41. data/proto_docs/grafeas/v1/provenance.rb +318 -0
  42. data/proto_docs/grafeas/v1/upgrade.rb +148 -0
  43. data/proto_docs/grafeas/v1/vulnerability.rb +245 -0
  44. metadata +225 -0
@@ -0,0 +1,77 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2020 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Grafeas
21
+ module V1
22
+ module Grafeas
23
+ # Path helper methods for the Grafeas API.
24
+ module Paths
25
+ ##
26
+ # Create a fully-qualified Note resource string.
27
+ #
28
+ # The resource will be in the following format:
29
+ #
30
+ # `projects/{project}/notes/{note}`
31
+ #
32
+ # @param project [String]
33
+ # @param note [String]
34
+ #
35
+ # @return [::String]
36
+ def note_path project:, note:
37
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
38
+
39
+ "projects/#{project}/notes/#{note}"
40
+ end
41
+
42
+ ##
43
+ # Create a fully-qualified Occurrence resource string.
44
+ #
45
+ # The resource will be in the following format:
46
+ #
47
+ # `projects/{project}/occurrences/{occurrence}`
48
+ #
49
+ # @param project [String]
50
+ # @param occurrence [String]
51
+ #
52
+ # @return [::String]
53
+ def occurrence_path project:, occurrence:
54
+ raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
55
+
56
+ "projects/#{project}/occurrences/#{occurrence}"
57
+ end
58
+
59
+ ##
60
+ # Create a fully-qualified Project resource string.
61
+ #
62
+ # The resource will be in the following format:
63
+ #
64
+ # `projects/{project}`
65
+ #
66
+ # @param project [String]
67
+ #
68
+ # @return [::String]
69
+ def project_path project:
70
+ "projects/#{project}"
71
+ end
72
+
73
+ extend self
74
+ end
75
+ end
76
+ end
77
+ end
@@ -0,0 +1,169 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: grafeas/v1/grafeas.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/api/annotations_pb'
7
+ require 'google/api/client_pb'
8
+ require 'google/api/field_behavior_pb'
9
+ require 'google/api/resource_pb'
10
+ require 'google/protobuf/empty_pb'
11
+ require 'google/protobuf/field_mask_pb'
12
+ require 'google/protobuf/timestamp_pb'
13
+ require 'grafeas/v1/attestation_pb'
14
+ require 'grafeas/v1/build_pb'
15
+ require 'grafeas/v1/common_pb'
16
+ require 'grafeas/v1/deployment_pb'
17
+ require 'grafeas/v1/discovery_pb'
18
+ require 'grafeas/v1/image_pb'
19
+ require 'grafeas/v1/package_pb'
20
+ require 'grafeas/v1/upgrade_pb'
21
+ require 'grafeas/v1/vulnerability_pb'
22
+ Google::Protobuf::DescriptorPool.generated_pool.build do
23
+ add_file("grafeas/v1/grafeas.proto", :syntax => :proto3) do
24
+ add_message "grafeas.v1.Occurrence" do
25
+ optional :name, :string, 1
26
+ optional :resource_uri, :string, 2
27
+ optional :note_name, :string, 3
28
+ optional :kind, :enum, 4, "grafeas.v1.NoteKind"
29
+ optional :remediation, :string, 5
30
+ optional :create_time, :message, 6, "google.protobuf.Timestamp"
31
+ optional :update_time, :message, 7, "google.protobuf.Timestamp"
32
+ oneof :details do
33
+ optional :vulnerability, :message, 8, "grafeas.v1.VulnerabilityOccurrence"
34
+ optional :build, :message, 9, "grafeas.v1.BuildOccurrence"
35
+ optional :image, :message, 10, "grafeas.v1.ImageOccurrence"
36
+ optional :package, :message, 11, "grafeas.v1.PackageOccurrence"
37
+ optional :deployment, :message, 12, "grafeas.v1.DeploymentOccurrence"
38
+ optional :discovery, :message, 13, "grafeas.v1.DiscoveryOccurrence"
39
+ optional :attestation, :message, 14, "grafeas.v1.AttestationOccurrence"
40
+ optional :upgrade, :message, 15, "grafeas.v1.UpgradeOccurrence"
41
+ end
42
+ end
43
+ add_message "grafeas.v1.Note" do
44
+ optional :name, :string, 1
45
+ optional :short_description, :string, 2
46
+ optional :long_description, :string, 3
47
+ optional :kind, :enum, 4, "grafeas.v1.NoteKind"
48
+ repeated :related_url, :message, 5, "grafeas.v1.RelatedUrl"
49
+ optional :expiration_time, :message, 6, "google.protobuf.Timestamp"
50
+ optional :create_time, :message, 7, "google.protobuf.Timestamp"
51
+ optional :update_time, :message, 8, "google.protobuf.Timestamp"
52
+ repeated :related_note_names, :string, 9
53
+ oneof :type do
54
+ optional :vulnerability, :message, 10, "grafeas.v1.VulnerabilityNote"
55
+ optional :build, :message, 11, "grafeas.v1.BuildNote"
56
+ optional :image, :message, 12, "grafeas.v1.ImageNote"
57
+ optional :package, :message, 13, "grafeas.v1.PackageNote"
58
+ optional :deployment, :message, 14, "grafeas.v1.DeploymentNote"
59
+ optional :discovery, :message, 15, "grafeas.v1.DiscoveryNote"
60
+ optional :attestation, :message, 16, "grafeas.v1.AttestationNote"
61
+ optional :upgrade, :message, 17, "grafeas.v1.UpgradeNote"
62
+ end
63
+ end
64
+ add_message "grafeas.v1.GetOccurrenceRequest" do
65
+ optional :name, :string, 1
66
+ end
67
+ add_message "grafeas.v1.ListOccurrencesRequest" do
68
+ optional :parent, :string, 1
69
+ optional :filter, :string, 2
70
+ optional :page_size, :int32, 3
71
+ optional :page_token, :string, 4
72
+ end
73
+ add_message "grafeas.v1.ListOccurrencesResponse" do
74
+ repeated :occurrences, :message, 1, "grafeas.v1.Occurrence"
75
+ optional :next_page_token, :string, 2
76
+ end
77
+ add_message "grafeas.v1.DeleteOccurrenceRequest" do
78
+ optional :name, :string, 1
79
+ end
80
+ add_message "grafeas.v1.CreateOccurrenceRequest" do
81
+ optional :parent, :string, 1
82
+ optional :occurrence, :message, 2, "grafeas.v1.Occurrence"
83
+ end
84
+ add_message "grafeas.v1.UpdateOccurrenceRequest" do
85
+ optional :name, :string, 1
86
+ optional :occurrence, :message, 2, "grafeas.v1.Occurrence"
87
+ optional :update_mask, :message, 3, "google.protobuf.FieldMask"
88
+ end
89
+ add_message "grafeas.v1.GetNoteRequest" do
90
+ optional :name, :string, 1
91
+ end
92
+ add_message "grafeas.v1.GetOccurrenceNoteRequest" do
93
+ optional :name, :string, 1
94
+ end
95
+ add_message "grafeas.v1.ListNotesRequest" do
96
+ optional :parent, :string, 1
97
+ optional :filter, :string, 2
98
+ optional :page_size, :int32, 3
99
+ optional :page_token, :string, 4
100
+ end
101
+ add_message "grafeas.v1.ListNotesResponse" do
102
+ repeated :notes, :message, 1, "grafeas.v1.Note"
103
+ optional :next_page_token, :string, 2
104
+ end
105
+ add_message "grafeas.v1.DeleteNoteRequest" do
106
+ optional :name, :string, 1
107
+ end
108
+ add_message "grafeas.v1.CreateNoteRequest" do
109
+ optional :parent, :string, 1
110
+ optional :note_id, :string, 2
111
+ optional :note, :message, 3, "grafeas.v1.Note"
112
+ end
113
+ add_message "grafeas.v1.UpdateNoteRequest" do
114
+ optional :name, :string, 1
115
+ optional :note, :message, 2, "grafeas.v1.Note"
116
+ optional :update_mask, :message, 3, "google.protobuf.FieldMask"
117
+ end
118
+ add_message "grafeas.v1.ListNoteOccurrencesRequest" do
119
+ optional :name, :string, 1
120
+ optional :filter, :string, 2
121
+ optional :page_size, :int32, 3
122
+ optional :page_token, :string, 4
123
+ end
124
+ add_message "grafeas.v1.ListNoteOccurrencesResponse" do
125
+ repeated :occurrences, :message, 1, "grafeas.v1.Occurrence"
126
+ optional :next_page_token, :string, 2
127
+ end
128
+ add_message "grafeas.v1.BatchCreateNotesRequest" do
129
+ optional :parent, :string, 1
130
+ map :notes, :string, :message, 2, "grafeas.v1.Note"
131
+ end
132
+ add_message "grafeas.v1.BatchCreateNotesResponse" do
133
+ repeated :notes, :message, 1, "grafeas.v1.Note"
134
+ end
135
+ add_message "grafeas.v1.BatchCreateOccurrencesRequest" do
136
+ optional :parent, :string, 1
137
+ repeated :occurrences, :message, 2, "grafeas.v1.Occurrence"
138
+ end
139
+ add_message "grafeas.v1.BatchCreateOccurrencesResponse" do
140
+ repeated :occurrences, :message, 1, "grafeas.v1.Occurrence"
141
+ end
142
+ end
143
+ end
144
+
145
+ module Grafeas
146
+ module V1
147
+ Occurrence = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Occurrence").msgclass
148
+ Note = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Note").msgclass
149
+ GetOccurrenceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.GetOccurrenceRequest").msgclass
150
+ ListOccurrencesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ListOccurrencesRequest").msgclass
151
+ ListOccurrencesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ListOccurrencesResponse").msgclass
152
+ DeleteOccurrenceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.DeleteOccurrenceRequest").msgclass
153
+ CreateOccurrenceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.CreateOccurrenceRequest").msgclass
154
+ UpdateOccurrenceRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.UpdateOccurrenceRequest").msgclass
155
+ GetNoteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.GetNoteRequest").msgclass
156
+ GetOccurrenceNoteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.GetOccurrenceNoteRequest").msgclass
157
+ ListNotesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ListNotesRequest").msgclass
158
+ ListNotesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ListNotesResponse").msgclass
159
+ DeleteNoteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.DeleteNoteRequest").msgclass
160
+ CreateNoteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.CreateNoteRequest").msgclass
161
+ UpdateNoteRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.UpdateNoteRequest").msgclass
162
+ ListNoteOccurrencesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ListNoteOccurrencesRequest").msgclass
163
+ ListNoteOccurrencesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ListNoteOccurrencesResponse").msgclass
164
+ BatchCreateNotesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.BatchCreateNotesRequest").msgclass
165
+ BatchCreateNotesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.BatchCreateNotesResponse").msgclass
166
+ BatchCreateOccurrencesRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.BatchCreateOccurrencesRequest").msgclass
167
+ BatchCreateOccurrencesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.BatchCreateOccurrencesResponse").msgclass
168
+ end
169
+ end
@@ -0,0 +1,85 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # Source: grafeas/v1/grafeas.proto for package 'grafeas.v1'
3
+ # Original file comments:
4
+ # Copyright 2019 The Grafeas Authors. All rights reserved.
5
+ #
6
+ # Licensed under the Apache License, Version 2.0 (the "License");
7
+ # you may not use this file except in compliance with the License.
8
+ # You may obtain a copy of the License at
9
+ #
10
+ # http://www.apache.org/licenses/LICENSE-2.0
11
+ #
12
+ # Unless required by applicable law or agreed to in writing, software
13
+ # distributed under the License is distributed on an "AS IS" BASIS,
14
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
+ # See the License for the specific language governing permissions and
16
+ # limitations under the License.
17
+ #
18
+
19
+ require 'grpc'
20
+ require 'grafeas/v1/grafeas_pb'
21
+
22
+ module Grafeas
23
+ module V1
24
+ module Grafeas
25
+ # [Grafeas](https://grafeas.io) API.
26
+ #
27
+ # Retrieves analysis results of Cloud components such as Docker container
28
+ # images.
29
+ #
30
+ # Analysis results are stored as a series of occurrences. An `Occurrence`
31
+ # contains information about a specific analysis instance on a resource. An
32
+ # occurrence refers to a `Note`. A note contains details describing the
33
+ # analysis and is generally stored in a separate project, called a `Provider`.
34
+ # Multiple occurrences can refer to the same note.
35
+ #
36
+ # For example, an SSL vulnerability could affect multiple images. In this case,
37
+ # there would be one note for the vulnerability and an occurrence for each
38
+ # image with the vulnerability referring to that note.
39
+ class Service
40
+
41
+ include GRPC::GenericService
42
+
43
+ self.marshal_class_method = :encode
44
+ self.unmarshal_class_method = :decode
45
+ self.service_name = 'grafeas.v1.Grafeas'
46
+
47
+ # Gets the specified occurrence.
48
+ rpc :GetOccurrence, GetOccurrenceRequest, Occurrence
49
+ # Lists occurrences for the specified project.
50
+ rpc :ListOccurrences, ListOccurrencesRequest, ListOccurrencesResponse
51
+ # Deletes the specified occurrence. For example, use this method to delete an
52
+ # occurrence when the occurrence is no longer applicable for the given
53
+ # resource.
54
+ rpc :DeleteOccurrence, DeleteOccurrenceRequest, Google::Protobuf::Empty
55
+ # Creates a new occurrence.
56
+ rpc :CreateOccurrence, CreateOccurrenceRequest, Occurrence
57
+ # Creates new occurrences in batch.
58
+ rpc :BatchCreateOccurrences, BatchCreateOccurrencesRequest, BatchCreateOccurrencesResponse
59
+ # Updates the specified occurrence.
60
+ rpc :UpdateOccurrence, UpdateOccurrenceRequest, Occurrence
61
+ # Gets the note attached to the specified occurrence. Consumer projects can
62
+ # use this method to get a note that belongs to a provider project.
63
+ rpc :GetOccurrenceNote, GetOccurrenceNoteRequest, Note
64
+ # Gets the specified note.
65
+ rpc :GetNote, GetNoteRequest, Note
66
+ # Lists notes for the specified project.
67
+ rpc :ListNotes, ListNotesRequest, ListNotesResponse
68
+ # Deletes the specified note.
69
+ rpc :DeleteNote, DeleteNoteRequest, Google::Protobuf::Empty
70
+ # Creates a new note.
71
+ rpc :CreateNote, CreateNoteRequest, Note
72
+ # Creates new notes in batch.
73
+ rpc :BatchCreateNotes, BatchCreateNotesRequest, BatchCreateNotesResponse
74
+ # Updates the specified note.
75
+ rpc :UpdateNote, UpdateNoteRequest, Note
76
+ # Lists occurrences referencing the specified note. Provider projects can use
77
+ # this method to get all occurrences across consumer projects referencing the
78
+ # specified note.
79
+ rpc :ListNoteOccurrences, ListNoteOccurrencesRequest, ListNoteOccurrencesResponse
80
+ end
81
+
82
+ Stub = Service.rpc_stub_class
83
+ end
84
+ end
85
+ end
@@ -0,0 +1,37 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: grafeas/v1/image.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_file("grafeas/v1/image.proto", :syntax => :proto3) do
8
+ add_message "grafeas.v1.Layer" do
9
+ optional :directive, :string, 1
10
+ optional :arguments, :string, 2
11
+ end
12
+ add_message "grafeas.v1.Fingerprint" do
13
+ optional :v1_name, :string, 1
14
+ repeated :v2_blob, :string, 2
15
+ optional :v2_name, :string, 3
16
+ end
17
+ add_message "grafeas.v1.ImageNote" do
18
+ optional :resource_url, :string, 1
19
+ optional :fingerprint, :message, 2, "grafeas.v1.Fingerprint"
20
+ end
21
+ add_message "grafeas.v1.ImageOccurrence" do
22
+ optional :fingerprint, :message, 1, "grafeas.v1.Fingerprint"
23
+ optional :distance, :int32, 2
24
+ repeated :layer_info, :message, 3, "grafeas.v1.Layer"
25
+ optional :base_resource_url, :string, 4
26
+ end
27
+ end
28
+ end
29
+
30
+ module Grafeas
31
+ module V1
32
+ Layer = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Layer").msgclass
33
+ Fingerprint = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Fingerprint").msgclass
34
+ ImageNote = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ImageNote").msgclass
35
+ ImageOccurrence = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ImageOccurrence").msgclass
36
+ end
37
+ end
@@ -0,0 +1,60 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: grafeas/v1/package.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ Google::Protobuf::DescriptorPool.generated_pool.build do
7
+ add_file("grafeas/v1/package.proto", :syntax => :proto3) do
8
+ add_message "grafeas.v1.Distribution" do
9
+ optional :cpe_uri, :string, 1
10
+ optional :architecture, :enum, 2, "grafeas.v1.Architecture"
11
+ optional :latest_version, :message, 3, "grafeas.v1.Version"
12
+ optional :maintainer, :string, 4
13
+ optional :url, :string, 5
14
+ optional :description, :string, 6
15
+ end
16
+ add_message "grafeas.v1.Location" do
17
+ optional :cpe_uri, :string, 1
18
+ optional :version, :message, 2, "grafeas.v1.Version"
19
+ optional :path, :string, 3
20
+ end
21
+ add_message "grafeas.v1.PackageNote" do
22
+ optional :name, :string, 1
23
+ repeated :distribution, :message, 10, "grafeas.v1.Distribution"
24
+ end
25
+ add_message "grafeas.v1.PackageOccurrence" do
26
+ optional :name, :string, 1
27
+ repeated :location, :message, 2, "grafeas.v1.Location"
28
+ end
29
+ add_message "grafeas.v1.Version" do
30
+ optional :epoch, :int32, 1
31
+ optional :name, :string, 2
32
+ optional :revision, :string, 3
33
+ optional :kind, :enum, 4, "grafeas.v1.Version.VersionKind"
34
+ optional :full_name, :string, 5
35
+ end
36
+ add_enum "grafeas.v1.Version.VersionKind" do
37
+ value :VERSION_KIND_UNSPECIFIED, 0
38
+ value :NORMAL, 1
39
+ value :MINIMUM, 2
40
+ value :MAXIMUM, 3
41
+ end
42
+ add_enum "grafeas.v1.Architecture" do
43
+ value :ARCHITECTURE_UNSPECIFIED, 0
44
+ value :X86, 1
45
+ value :X64, 2
46
+ end
47
+ end
48
+ end
49
+
50
+ module Grafeas
51
+ module V1
52
+ Distribution = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Distribution").msgclass
53
+ Location = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Location").msgclass
54
+ PackageNote = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.PackageNote").msgclass
55
+ PackageOccurrence = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.PackageOccurrence").msgclass
56
+ Version = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Version").msgclass
57
+ Version::VersionKind = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Version.VersionKind").enummodule
58
+ Architecture = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Architecture").enummodule
59
+ end
60
+ end
@@ -0,0 +1,117 @@
1
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
2
+ # source: grafeas/v1/provenance.proto
3
+
4
+ require 'google/protobuf'
5
+
6
+ require 'google/protobuf/timestamp_pb'
7
+ Google::Protobuf::DescriptorPool.generated_pool.build do
8
+ add_file("grafeas/v1/provenance.proto", :syntax => :proto3) do
9
+ add_message "grafeas.v1.BuildProvenance" do
10
+ optional :id, :string, 1
11
+ optional :project_id, :string, 2
12
+ repeated :commands, :message, 3, "grafeas.v1.Command"
13
+ repeated :built_artifacts, :message, 4, "grafeas.v1.Artifact"
14
+ optional :create_time, :message, 5, "google.protobuf.Timestamp"
15
+ optional :start_time, :message, 6, "google.protobuf.Timestamp"
16
+ optional :end_time, :message, 7, "google.protobuf.Timestamp"
17
+ optional :creator, :string, 8
18
+ optional :logs_uri, :string, 9
19
+ optional :source_provenance, :message, 10, "grafeas.v1.Source"
20
+ optional :trigger_id, :string, 11
21
+ map :build_options, :string, :string, 12
22
+ optional :builder_version, :string, 13
23
+ end
24
+ add_message "grafeas.v1.Source" do
25
+ optional :artifact_storage_source_uri, :string, 1
26
+ map :file_hashes, :string, :message, 2, "grafeas.v1.FileHashes"
27
+ optional :context, :message, 3, "grafeas.v1.SourceContext"
28
+ repeated :additional_contexts, :message, 4, "grafeas.v1.SourceContext"
29
+ end
30
+ add_message "grafeas.v1.FileHashes" do
31
+ repeated :file_hash, :message, 1, "grafeas.v1.Hash"
32
+ end
33
+ add_message "grafeas.v1.Hash" do
34
+ optional :type, :string, 1
35
+ optional :value, :bytes, 2
36
+ end
37
+ add_message "grafeas.v1.Command" do
38
+ optional :name, :string, 1
39
+ repeated :env, :string, 2
40
+ repeated :args, :string, 3
41
+ optional :dir, :string, 4
42
+ optional :id, :string, 5
43
+ repeated :wait_for, :string, 6
44
+ end
45
+ add_message "grafeas.v1.Artifact" do
46
+ optional :checksum, :string, 1
47
+ optional :id, :string, 2
48
+ repeated :names, :string, 3
49
+ end
50
+ add_message "grafeas.v1.SourceContext" do
51
+ map :labels, :string, :string, 4
52
+ oneof :context do
53
+ optional :cloud_repo, :message, 1, "grafeas.v1.CloudRepoSourceContext"
54
+ optional :gerrit, :message, 2, "grafeas.v1.GerritSourceContext"
55
+ optional :git, :message, 3, "grafeas.v1.GitSourceContext"
56
+ end
57
+ end
58
+ add_message "grafeas.v1.AliasContext" do
59
+ optional :kind, :enum, 1, "grafeas.v1.AliasContext.Kind"
60
+ optional :name, :string, 2
61
+ end
62
+ add_enum "grafeas.v1.AliasContext.Kind" do
63
+ value :KIND_UNSPECIFIED, 0
64
+ value :FIXED, 1
65
+ value :MOVABLE, 2
66
+ value :OTHER, 4
67
+ end
68
+ add_message "grafeas.v1.CloudRepoSourceContext" do
69
+ optional :repo_id, :message, 1, "grafeas.v1.RepoId"
70
+ oneof :revision do
71
+ optional :revision_id, :string, 2
72
+ optional :alias_context, :message, 3, "grafeas.v1.AliasContext"
73
+ end
74
+ end
75
+ add_message "grafeas.v1.GerritSourceContext" do
76
+ optional :host_uri, :string, 1
77
+ optional :gerrit_project, :string, 2
78
+ oneof :revision do
79
+ optional :revision_id, :string, 3
80
+ optional :alias_context, :message, 4, "grafeas.v1.AliasContext"
81
+ end
82
+ end
83
+ add_message "grafeas.v1.GitSourceContext" do
84
+ optional :url, :string, 1
85
+ optional :revision_id, :string, 2
86
+ end
87
+ add_message "grafeas.v1.RepoId" do
88
+ oneof :id do
89
+ optional :project_repo_id, :message, 1, "grafeas.v1.ProjectRepoId"
90
+ optional :uid, :string, 2
91
+ end
92
+ end
93
+ add_message "grafeas.v1.ProjectRepoId" do
94
+ optional :project_id, :string, 1
95
+ optional :repo_name, :string, 2
96
+ end
97
+ end
98
+ end
99
+
100
+ module Grafeas
101
+ module V1
102
+ BuildProvenance = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.BuildProvenance").msgclass
103
+ Source = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Source").msgclass
104
+ FileHashes = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.FileHashes").msgclass
105
+ Hash = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Hash").msgclass
106
+ Command = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Command").msgclass
107
+ Artifact = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.Artifact").msgclass
108
+ SourceContext = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.SourceContext").msgclass
109
+ AliasContext = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.AliasContext").msgclass
110
+ AliasContext::Kind = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.AliasContext.Kind").enummodule
111
+ CloudRepoSourceContext = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.CloudRepoSourceContext").msgclass
112
+ GerritSourceContext = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.GerritSourceContext").msgclass
113
+ GitSourceContext = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.GitSourceContext").msgclass
114
+ RepoId = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.RepoId").msgclass
115
+ ProjectRepoId = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("grafeas.v1.ProjectRepoId").msgclass
116
+ end
117
+ end