google-cloud-binary_authorization-v1beta1 0.19.0 → 0.20.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: cc93381ffc32e4a219b1f84c01803fce8b10b153a04b363f72d361ea06607908
4
- data.tar.gz: 4d3531137217ab30abf830d6de6a666d30b39a227e53049f38f89e9df51fc2bf
3
+ metadata.gz: 768546790de0b4b80240d30f78d010315e7150a1c182ecd77c84c305d70508ab
4
+ data.tar.gz: e81a0335f0941fb190ab8b9a26fa66073455269d63cfceedbe7f15babbc2d75e
5
5
  SHA512:
6
- metadata.gz: e03d1091b19ccb0d0f6b888b3a9c3e258edf7a97ee394b05faa107789d29b1ac3b1918c42451b89fd9b2b0878e53be668f0412e4b58bbfa7e10b89891b2cc8e6
7
- data.tar.gz: 66558bda594d3b317bd3ea22e74004187dc9b4bed42167613efaac39da25c0d4ce33a01d9ae45933b45049e073925fdbe845cb32c52cd4acd6d6f4d04aea5262
6
+ metadata.gz: a790925dd9490e8d379f4a764fd197a5e33030472106d4e2e2daacecb98b5474d85c7b3dae0ccb20e7dc621fb19cdb82a621a70cb4393054beab9727d0570294
7
+ data.tar.gz: 7dc0277e5cb731abd8f33aafd1ceae5b57362347c86b70bd5f873c77ce64dc4856315bd0a275fa591284be0da2a2d3a01aeeeff0eefb16b3c5894497a3125df1
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Ruby Client for the Binary Authorization V1beta1 API
2
2
 
3
- The management interface for Binary Authorization, a system providing policy control for images deployed to Kubernetes Engine clusters, Anthos clusters on VMware, and Cloud Run.
3
+ The management interface for Binary Authorization, a service that provides policy-based deployment validation and control for images deployed to Google Kubernetes Engine (GKE), Anthos Service Mesh, Anthos Clusters, and Cloud Run.
4
4
 
5
5
  Binary Authorization is a service on Google Cloud that provides centralized software supply-chain security for applications that run on Google Kubernetes Engine (GKE) and GKE on-prem.
6
6
 
@@ -18,6 +18,7 @@
18
18
 
19
19
  require "google/cloud/errors"
20
20
  require "google/cloud/binaryauthorization/v1beta1/service_pb"
21
+ require "google/iam/v1"
21
22
 
22
23
  module Google
23
24
  module Cloud
@@ -208,8 +209,23 @@ module Google
208
209
  entry.set "defaultTimeout", @config.timeout if @config.timeout
209
210
  entry.set "quotaProject", @quota_project_id if @quota_project_id
210
211
  end
212
+
213
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Client.new do |config|
214
+ config.credentials = credentials
215
+ config.quota_project = @quota_project_id
216
+ config.endpoint = @binauthz_management_service_stub.endpoint
217
+ config.universe_domain = @binauthz_management_service_stub.universe_domain
218
+ config.logger = @binauthz_management_service_stub.logger if config.respond_to? :logger=
219
+ end
211
220
  end
212
221
 
222
+ ##
223
+ # Get the associated client for mix-in of the IAMPolicy.
224
+ #
225
+ # @return [Google::Iam::V1::IAMPolicy::Client]
226
+ #
227
+ attr_reader :iam_policy_client
228
+
213
229
  ##
214
230
  # The logger used for request/response debug logging.
215
231
  #
@@ -222,13 +238,16 @@ module Google
222
238
  # Service calls
223
239
 
224
240
  ##
225
- # A {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} specifies the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} that must attest to
226
- # a container image, before the project is allowed to deploy that
241
+ # A {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} specifies the
242
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} that must
243
+ # attest to a container image, before the project is allowed to deploy that
227
244
  # image. There is at most one policy per project. All image admission
228
245
  # requests are permitted if a project has no policy.
229
246
  #
230
- # Gets the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} for this project. Returns a default
231
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} if the project does not have one.
247
+ # Gets the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} for this
248
+ # project. Returns a default
249
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} if the project
250
+ # does not have one.
232
251
  #
233
252
  # @overload get_policy(request, options = nil)
234
253
  # Pass arguments to `get_policy` via a request object, either of type
@@ -246,8 +265,9 @@ module Google
246
265
  # the default parameter values, pass an empty Hash as a request object (see above).
247
266
  #
248
267
  # @param name [::String]
249
- # Required. The resource name of the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} to retrieve,
250
- # in the format `projects/*/policy`.
268
+ # Required. The resource name of the
269
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} to retrieve, in
270
+ # the format `projects/*/policy`.
251
271
  #
252
272
  # @yield [response, operation] Access the result along with the RPC operation
253
273
  # @yieldparam response [::Google::Cloud::BinaryAuthorization::V1beta1::Policy]
@@ -314,11 +334,13 @@ module Google
314
334
  end
315
335
 
316
336
  ##
317
- # Creates or updates a project's {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}, and returns a copy of the
318
- # new {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}. A policy is always updated as a whole, to avoid race
319
- # conditions with concurrent policy enforcement (or management!)
320
- # requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT
321
- # if the request is malformed.
337
+ # Creates or updates a project's
338
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}, and returns a
339
+ # copy of the new {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}.
340
+ # A policy is always updated as a whole, to avoid race conditions with
341
+ # concurrent policy enforcement (or management!) requests. Returns NOT_FOUND
342
+ # if the project does not exist, INVALID_ARGUMENT if the request is
343
+ # malformed.
322
344
  #
323
345
  # @overload update_policy(request, options = nil)
324
346
  # Pass arguments to `update_policy` via a request object, either of type
@@ -336,9 +358,11 @@ module Google
336
358
  # the default parameter values, pass an empty Hash as a request object (see above).
337
359
  #
338
360
  # @param policy [::Google::Cloud::BinaryAuthorization::V1beta1::Policy, ::Hash]
339
- # Required. A new or updated {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} value. The service will
340
- # overwrite the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy#name policy name} field with the resource name in
341
- # the request URL, in the format `projects/*/policy`.
361
+ # Required. A new or updated
362
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} value. The
363
+ # service will overwrite the [policy
364
+ # name][google.cloud.binaryauthorization.v1beta1.Policy.name] field with the
365
+ # resource name in the request URL, in the format `projects/*/policy`.
342
366
  #
343
367
  # @yield [response, operation] Access the result along with the RPC operation
344
368
  # @yieldparam response [::Google::Cloud::BinaryAuthorization::V1beta1::Policy]
@@ -405,10 +429,13 @@ module Google
405
429
  end
406
430
 
407
431
  ##
408
- # Creates an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}, and returns a copy of the new
409
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}. Returns NOT_FOUND if the project does not exist,
410
- # INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the
411
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} already exists.
432
+ # Creates an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor},
433
+ # and returns a copy of the new
434
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}. Returns
435
+ # NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is
436
+ # malformed, ALREADY_EXISTS if the
437
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} already
438
+ # exists.
412
439
  #
413
440
  # @overload create_attestor(request, options = nil)
414
441
  # Pass arguments to `create_attestor` via a request object, either of type
@@ -426,13 +453,17 @@ module Google
426
453
  # the default parameter values, pass an empty Hash as a request object (see above).
427
454
  #
428
455
  # @param parent [::String]
429
- # Required. The parent of this {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
456
+ # Required. The parent of this
457
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
430
458
  # @param attestor_id [::String]
431
- # Required. The {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} ID.
459
+ # Required. The
460
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} ID.
432
461
  # @param attestor [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor, ::Hash]
433
- # Required. The initial {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The service will
434
- # overwrite the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor#name attestor name} field with the resource name,
435
- # in the format `projects/*/attestors/*`.
462
+ # Required. The initial
463
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The
464
+ # service will overwrite the [attestor
465
+ # name][google.cloud.binaryauthorization.v1beta1.Attestor.name] field with
466
+ # the resource name, in the format `projects/*/attestors/*`.
436
467
  #
437
468
  # @yield [response, operation] Access the result along with the RPC operation
438
469
  # @yieldparam response [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor]
@@ -500,7 +531,9 @@ module Google
500
531
 
501
532
  ##
502
533
  # Gets an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
503
- # Returns NOT_FOUND if the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not exist.
534
+ # Returns NOT_FOUND if the
535
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not
536
+ # exist.
504
537
  #
505
538
  # @overload get_attestor(request, options = nil)
506
539
  # Pass arguments to `get_attestor` via a request object, either of type
@@ -518,8 +551,9 @@ module Google
518
551
  # the default parameter values, pass an empty Hash as a request object (see above).
519
552
  #
520
553
  # @param name [::String]
521
- # Required. The name of the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} to retrieve, in the format
522
- # `projects/*/attestors/*`.
554
+ # Required. The name of the
555
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} to retrieve,
556
+ # in the format `projects/*/attestors/*`.
523
557
  #
524
558
  # @yield [response, operation] Access the result along with the RPC operation
525
559
  # @yieldparam response [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor]
@@ -587,7 +621,9 @@ module Google
587
621
 
588
622
  ##
589
623
  # Updates an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
590
- # Returns NOT_FOUND if the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not exist.
624
+ # Returns NOT_FOUND if the
625
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not
626
+ # exist.
591
627
  #
592
628
  # @overload update_attestor(request, options = nil)
593
629
  # Pass arguments to `update_attestor` via a request object, either of type
@@ -605,9 +641,12 @@ module Google
605
641
  # the default parameter values, pass an empty Hash as a request object (see above).
606
642
  #
607
643
  # @param attestor [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor, ::Hash]
608
- # Required. The updated {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The service will
609
- # overwrite the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor#name attestor name} field with the resource name
610
- # in the request URL, in the format `projects/*/attestors/*`.
644
+ # Required. The updated
645
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The
646
+ # service will overwrite the [attestor
647
+ # name][google.cloud.binaryauthorization.v1beta1.Attestor.name] field with
648
+ # the resource name in the request URL, in the format
649
+ # `projects/*/attestors/*`.
611
650
  #
612
651
  # @yield [response, operation] Access the result along with the RPC operation
613
652
  # @yieldparam response [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor]
@@ -694,14 +733,16 @@ module Google
694
733
  #
695
734
  # @param parent [::String]
696
735
  # Required. The resource name of the project associated with the
697
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors}, in the format `projects/*`.
736
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors}, in the
737
+ # format `projects/*`.
698
738
  # @param page_size [::Integer]
699
739
  # Requested page size. The server may return fewer results than requested. If
700
740
  # unspecified, the server will pick an appropriate default.
701
741
  # @param page_token [::String]
702
742
  # A token identifying a page of results the server should return. Typically,
703
- # this is the value of {::Google::Cloud::BinaryAuthorization::V1beta1::ListAttestorsResponse#next_page_token ListAttestorsResponse.next_page_token} returned
704
- # from the previous call to the `ListAttestors` method.
743
+ # this is the value of
744
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::ListAttestorsResponse#next_page_token ListAttestorsResponse.next_page_token}
745
+ # returned from the previous call to the `ListAttestors` method.
705
746
  #
706
747
  # @yield [response, operation] Access the result along with the RPC operation
707
748
  # @yieldparam response [::Gapic::PagedEnumerable<::Google::Cloud::BinaryAuthorization::V1beta1::Attestor>]
@@ -774,8 +815,10 @@ module Google
774
815
  end
775
816
 
776
817
  ##
777
- # Deletes an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}. Returns NOT_FOUND if the
778
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not exist.
818
+ # Deletes an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
819
+ # Returns NOT_FOUND if the
820
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not
821
+ # exist.
779
822
  #
780
823
  # @overload delete_attestor(request, options = nil)
781
824
  # Pass arguments to `delete_attestor` via a request object, either of type
@@ -793,8 +836,9 @@ module Google
793
836
  # the default parameter values, pass an empty Hash as a request object (see above).
794
837
  #
795
838
  # @param name [::String]
796
- # Required. The name of the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} to delete, in the format
797
- # `projects/*/attestors/*`.
839
+ # Required. The name of the
840
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} to delete,
841
+ # in the format `projects/*/attestors/*`.
798
842
  #
799
843
  # @yield [response, operation] Access the result along with the RPC operation
800
844
  # @yieldparam response [::Google::Protobuf::Empty]
@@ -19,6 +19,7 @@
19
19
  require "google/cloud/errors"
20
20
  require "google/cloud/binaryauthorization/v1beta1/service_pb"
21
21
  require "google/cloud/binary_authorization/v1beta1/binauthz_management_service/rest/service_stub"
22
+ require "google/iam/v1/rest"
22
23
 
23
24
  module Google
24
25
  module Cloud
@@ -201,8 +202,24 @@ module Google
201
202
  entry.set "defaultTimeout", @config.timeout if @config.timeout
202
203
  entry.set "quotaProject", @quota_project_id if @quota_project_id
203
204
  end
205
+
206
+ @iam_policy_client = Google::Iam::V1::IAMPolicy::Rest::Client.new do |config|
207
+ config.credentials = credentials
208
+ config.quota_project = @quota_project_id
209
+ config.endpoint = @binauthz_management_service_stub.endpoint
210
+ config.universe_domain = @binauthz_management_service_stub.universe_domain
211
+ config.bindings_override = @config.bindings_override
212
+ config.logger = @binauthz_management_service_stub.logger if config.respond_to? :logger=
213
+ end
204
214
  end
205
215
 
216
+ ##
217
+ # Get the associated client for mix-in of the IAMPolicy.
218
+ #
219
+ # @return [Google::Iam::V1::IAMPolicy::Rest::Client]
220
+ #
221
+ attr_reader :iam_policy_client
222
+
206
223
  ##
207
224
  # The logger used for request/response debug logging.
208
225
  #
@@ -215,13 +232,16 @@ module Google
215
232
  # Service calls
216
233
 
217
234
  ##
218
- # A {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} specifies the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} that must attest to
219
- # a container image, before the project is allowed to deploy that
235
+ # A {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} specifies the
236
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} that must
237
+ # attest to a container image, before the project is allowed to deploy that
220
238
  # image. There is at most one policy per project. All image admission
221
239
  # requests are permitted if a project has no policy.
222
240
  #
223
- # Gets the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} for this project. Returns a default
224
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} if the project does not have one.
241
+ # Gets the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} for this
242
+ # project. Returns a default
243
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} if the project
244
+ # does not have one.
225
245
  #
226
246
  # @overload get_policy(request, options = nil)
227
247
  # Pass arguments to `get_policy` via a request object, either of type
@@ -239,8 +259,9 @@ module Google
239
259
  # the default parameter values, pass an empty Hash as a request object (see above).
240
260
  #
241
261
  # @param name [::String]
242
- # Required. The resource name of the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} to retrieve,
243
- # in the format `projects/*/policy`.
262
+ # Required. The resource name of the
263
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} to retrieve, in
264
+ # the format `projects/*/policy`.
244
265
  # @yield [result, operation] Access the result along with the TransportOperation object
245
266
  # @yieldparam result [::Google::Cloud::BinaryAuthorization::V1beta1::Policy]
246
267
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -300,11 +321,13 @@ module Google
300
321
  end
301
322
 
302
323
  ##
303
- # Creates or updates a project's {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}, and returns a copy of the
304
- # new {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}. A policy is always updated as a whole, to avoid race
305
- # conditions with concurrent policy enforcement (or management!)
306
- # requests. Returns NOT_FOUND if the project does not exist, INVALID_ARGUMENT
307
- # if the request is malformed.
324
+ # Creates or updates a project's
325
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}, and returns a
326
+ # copy of the new {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy}.
327
+ # A policy is always updated as a whole, to avoid race conditions with
328
+ # concurrent policy enforcement (or management!) requests. Returns NOT_FOUND
329
+ # if the project does not exist, INVALID_ARGUMENT if the request is
330
+ # malformed.
308
331
  #
309
332
  # @overload update_policy(request, options = nil)
310
333
  # Pass arguments to `update_policy` via a request object, either of type
@@ -322,9 +345,11 @@ module Google
322
345
  # the default parameter values, pass an empty Hash as a request object (see above).
323
346
  #
324
347
  # @param policy [::Google::Cloud::BinaryAuthorization::V1beta1::Policy, ::Hash]
325
- # Required. A new or updated {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} value. The service will
326
- # overwrite the {::Google::Cloud::BinaryAuthorization::V1beta1::Policy#name policy name} field with the resource name in
327
- # the request URL, in the format `projects/*/policy`.
348
+ # Required. A new or updated
349
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Policy policy} value. The
350
+ # service will overwrite the [policy
351
+ # name][google.cloud.binaryauthorization.v1beta1.Policy.name] field with the
352
+ # resource name in the request URL, in the format `projects/*/policy`.
328
353
  # @yield [result, operation] Access the result along with the TransportOperation object
329
354
  # @yieldparam result [::Google::Cloud::BinaryAuthorization::V1beta1::Policy]
330
355
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -384,10 +409,13 @@ module Google
384
409
  end
385
410
 
386
411
  ##
387
- # Creates an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}, and returns a copy of the new
388
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}. Returns NOT_FOUND if the project does not exist,
389
- # INVALID_ARGUMENT if the request is malformed, ALREADY_EXISTS if the
390
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} already exists.
412
+ # Creates an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor},
413
+ # and returns a copy of the new
414
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}. Returns
415
+ # NOT_FOUND if the project does not exist, INVALID_ARGUMENT if the request is
416
+ # malformed, ALREADY_EXISTS if the
417
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} already
418
+ # exists.
391
419
  #
392
420
  # @overload create_attestor(request, options = nil)
393
421
  # Pass arguments to `create_attestor` via a request object, either of type
@@ -405,13 +433,17 @@ module Google
405
433
  # the default parameter values, pass an empty Hash as a request object (see above).
406
434
  #
407
435
  # @param parent [::String]
408
- # Required. The parent of this {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
436
+ # Required. The parent of this
437
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
409
438
  # @param attestor_id [::String]
410
- # Required. The {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} ID.
439
+ # Required. The
440
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} ID.
411
441
  # @param attestor [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor, ::Hash]
412
- # Required. The initial {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The service will
413
- # overwrite the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor#name attestor name} field with the resource name,
414
- # in the format `projects/*/attestors/*`.
442
+ # Required. The initial
443
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The
444
+ # service will overwrite the [attestor
445
+ # name][google.cloud.binaryauthorization.v1beta1.Attestor.name] field with
446
+ # the resource name, in the format `projects/*/attestors/*`.
415
447
  # @yield [result, operation] Access the result along with the TransportOperation object
416
448
  # @yieldparam result [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor]
417
449
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -472,7 +504,9 @@ module Google
472
504
 
473
505
  ##
474
506
  # Gets an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
475
- # Returns NOT_FOUND if the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not exist.
507
+ # Returns NOT_FOUND if the
508
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not
509
+ # exist.
476
510
  #
477
511
  # @overload get_attestor(request, options = nil)
478
512
  # Pass arguments to `get_attestor` via a request object, either of type
@@ -490,8 +524,9 @@ module Google
490
524
  # the default parameter values, pass an empty Hash as a request object (see above).
491
525
  #
492
526
  # @param name [::String]
493
- # Required. The name of the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} to retrieve, in the format
494
- # `projects/*/attestors/*`.
527
+ # Required. The name of the
528
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} to retrieve,
529
+ # in the format `projects/*/attestors/*`.
495
530
  # @yield [result, operation] Access the result along with the TransportOperation object
496
531
  # @yieldparam result [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor]
497
532
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -552,7 +587,9 @@ module Google
552
587
 
553
588
  ##
554
589
  # Updates an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
555
- # Returns NOT_FOUND if the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not exist.
590
+ # Returns NOT_FOUND if the
591
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not
592
+ # exist.
556
593
  #
557
594
  # @overload update_attestor(request, options = nil)
558
595
  # Pass arguments to `update_attestor` via a request object, either of type
@@ -570,9 +607,12 @@ module Google
570
607
  # the default parameter values, pass an empty Hash as a request object (see above).
571
608
  #
572
609
  # @param attestor [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor, ::Hash]
573
- # Required. The updated {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The service will
574
- # overwrite the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor#name attestor name} field with the resource name
575
- # in the request URL, in the format `projects/*/attestors/*`.
610
+ # Required. The updated
611
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} value. The
612
+ # service will overwrite the [attestor
613
+ # name][google.cloud.binaryauthorization.v1beta1.Attestor.name] field with
614
+ # the resource name in the request URL, in the format
615
+ # `projects/*/attestors/*`.
576
616
  # @yield [result, operation] Access the result along with the TransportOperation object
577
617
  # @yieldparam result [::Google::Cloud::BinaryAuthorization::V1beta1::Attestor]
578
618
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -652,14 +692,16 @@ module Google
652
692
  #
653
693
  # @param parent [::String]
654
694
  # Required. The resource name of the project associated with the
655
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors}, in the format `projects/*`.
695
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors}, in the
696
+ # format `projects/*`.
656
697
  # @param page_size [::Integer]
657
698
  # Requested page size. The server may return fewer results than requested. If
658
699
  # unspecified, the server will pick an appropriate default.
659
700
  # @param page_token [::String]
660
701
  # A token identifying a page of results the server should return. Typically,
661
- # this is the value of {::Google::Cloud::BinaryAuthorization::V1beta1::ListAttestorsResponse#next_page_token ListAttestorsResponse.next_page_token} returned
662
- # from the previous call to the `ListAttestors` method.
702
+ # this is the value of
703
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::ListAttestorsResponse#next_page_token ListAttestorsResponse.next_page_token}
704
+ # returned from the previous call to the `ListAttestors` method.
663
705
  # @yield [result, operation] Access the result along with the TransportOperation object
664
706
  # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::BinaryAuthorization::V1beta1::Attestor>]
665
707
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -725,8 +767,10 @@ module Google
725
767
  end
726
768
 
727
769
  ##
728
- # Deletes an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}. Returns NOT_FOUND if the
729
- # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not exist.
770
+ # Deletes an {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor}.
771
+ # Returns NOT_FOUND if the
772
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestor} does not
773
+ # exist.
730
774
  #
731
775
  # @overload delete_attestor(request, options = nil)
732
776
  # Pass arguments to `delete_attestor` via a request object, either of type
@@ -744,8 +788,9 @@ module Google
744
788
  # the default parameter values, pass an empty Hash as a request object (see above).
745
789
  #
746
790
  # @param name [::String]
747
- # Required. The name of the {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} to delete, in the format
748
- # `projects/*/attestors/*`.
791
+ # Required. The name of the
792
+ # {::Google::Cloud::BinaryAuthorization::V1beta1::Attestor attestors} to delete,
793
+ # in the format `projects/*/attestors/*`.
749
794
  # @yield [result, operation] Access the result along with the TransportOperation object
750
795
  # @yieldparam result [::Google::Protobuf::Empty]
751
796
  # @yieldparam operation [::Gapic::Rest::TransportOperation]
@@ -912,6 +957,13 @@ module Google
912
957
  config_attr :retry_policy, nil, ::Hash, ::Proc, nil
913
958
  config_attr :quota_project, nil, ::String, nil
914
959
  config_attr :universe_domain, nil, ::String, nil
960
+
961
+ # @private
962
+ # Overrides for http bindings for the RPCs of this service
963
+ # are only used when this service is used as mixin, and only
964
+ # by the host service.
965
+ # @return [::Hash{::Symbol=>::Array<::Gapic::Rest::GrpcTranscoder::HttpBinding>}]
966
+ config_attr :bindings_override, {}, ::Hash, nil
915
967
  config_attr :logger, :default, ::Logger, nil, :default
916
968
 
917
969
  # @private
@@ -21,6 +21,7 @@ require "gapic/config"
21
21
  require "gapic/config/method"
22
22
 
23
23
  require "google/cloud/binary_authorization/v1beta1/version"
24
+ require "google/cloud/binary_authorization/v1beta1/bindings_override"
24
25
 
25
26
  require "google/cloud/binary_authorization/v1beta1/binauthz_management_service/credentials"
26
27
  require "google/cloud/binary_authorization/v1beta1/binauthz_management_service/paths"
@@ -0,0 +1,110 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2026 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
+ require "gapic/rest"
20
+
21
+ module Google
22
+ module Cloud
23
+ module BinaryAuthorization
24
+ ##
25
+ # @example Loading just the REST part of this package, including all its services, and instantiating a REST client
26
+ #
27
+ # require "google/cloud/binary_authorization/v1beta1/rest"
28
+ # client = ::Google::Cloud::BinaryAuthorization::V1beta1::BinauthzManagementService::Rest::Client.new
29
+ #
30
+ module V1beta1
31
+ ##
32
+ # @private
33
+ # Initialize the mixin bindings configuration
34
+ #
35
+ def self.configure
36
+ @configure ||= begin
37
+ namespace = ["Google", "Cloud", "BinaryAuthorization"]
38
+ parent_config = while namespace.any?
39
+ parent_name = namespace.join "::"
40
+ parent_const = const_get parent_name
41
+ break parent_const.configure if parent_const.respond_to? :configure
42
+ namespace.pop
43
+ end
44
+
45
+ default_config = ::Gapic::Rest::HttpBindingOverrideConfiguration.new parent_config
46
+ default_config.bindings_override["google.iam.v1.IAMPolicy.GetIamPolicy"] = [
47
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
48
+ uri_method: :get,
49
+ uri_template: "/v1beta1/{resource}:getIamPolicy",
50
+ matches: [
51
+ ["resource", %r{^projects/[^/]+/policy/?$}, false]
52
+ ],
53
+ body: nil
54
+ ),
55
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
56
+ uri_method: :get,
57
+ uri_template: "/v1beta1/{resource}:getIamPolicy",
58
+ matches: [
59
+ ["resource", %r{^projects/[^/]+/attestors/[^/]+/?$}, false]
60
+ ],
61
+ body: nil
62
+ )
63
+ ]
64
+ default_config.bindings_override["google.iam.v1.IAMPolicy.SetIamPolicy"] = [
65
+
66
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
67
+ uri_method: :post,
68
+ uri_template: "/v1beta1/{resource}:setIamPolicy",
69
+ matches: [
70
+ ["resource", %r{^projects/[^/]+/policy/?$}, false]
71
+ ],
72
+ body: "*"
73
+ ),
74
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
75
+ uri_method: :post,
76
+ uri_template: "/v1beta1/{resource}:setIamPolicy",
77
+ matches: [
78
+ ["resource", %r{^projects/[^/]+/attestors/[^/]+/?$}, false]
79
+ ],
80
+ body: "*"
81
+ )
82
+ ]
83
+ default_config.bindings_override["google.iam.v1.IAMPolicy.TestIamPermissions"] = [
84
+
85
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
86
+ uri_method: :post,
87
+ uri_template: "/v1beta1/{resource}:testIamPermissions",
88
+ matches: [
89
+ ["resource", %r{^projects/[^/]+/policy/?$}, false]
90
+ ],
91
+ body: "*"
92
+ ),
93
+ Gapic::Rest::GrpcTranscoder::HttpBinding.create_with_validation(
94
+ uri_method: :post,
95
+ uri_template: "/v1beta1/{resource}:testIamPermissions",
96
+ matches: [
97
+ ["resource", %r{^projects/[^/]+/attestors/[^/]+/?$}, false]
98
+ ],
99
+ body: "*"
100
+ )
101
+ ]
102
+ default_config
103
+ end
104
+ yield @configure if block_given?
105
+ @configure
106
+ end
107
+ end
108
+ end
109
+ end
110
+ end
@@ -18,6 +18,7 @@
18
18
 
19
19
  require "google/cloud/binary_authorization/v1beta1/binauthz_management_service/rest"
20
20
  require "google/cloud/binary_authorization/v1beta1/system_policy/rest"
21
+ require "google/cloud/binary_authorization/v1beta1/bindings_override"
21
22
  require "google/cloud/binary_authorization/v1beta1/version"
22
23
 
23
24
  module Google