pub struct SecurityCenterSettingsServiceClient<T> { /* private fields */ }
Expand description

§API Overview

The SecurityCenterSettingsService is a sub-api of securitycenter.googleapis.com. The service provides methods to manage Security Center Settings, and Component Settings for GCP organizations, folders, projects, and clusters.

Implementations§

source§

impl<T> SecurityCenterSettingsServiceClient<T>
where T: GrpcService<BoxBody>, T::Error: Into<StdError>, T::ResponseBody: Body<Data = Bytes> + Send + 'static, <T::ResponseBody as Body>::Error: Into<StdError> + Send,

source

pub fn new(inner: T) -> Self

source

pub fn with_origin(inner: T, origin: Uri) -> Self

source

pub fn with_interceptor<F>( inner: T, interceptor: F ) -> SecurityCenterSettingsServiceClient<InterceptedService<T, F>>
where F: Interceptor, T::ResponseBody: Default, T: Service<Request<BoxBody>, Response = Response<<T as GrpcService<BoxBody>>::ResponseBody>>, <T as Service<Request<BoxBody>>>::Error: Into<StdError> + Send + Sync,

source

pub fn send_compressed(self, encoding: CompressionEncoding) -> Self

Compress requests with the given encoding.

This requires the server to support it otherwise it might respond with an error.

source

pub fn accept_compressed(self, encoding: CompressionEncoding) -> Self

Enable decompressing responses.

source

pub fn max_decoding_message_size(self, limit: usize) -> Self

Limits the maximum size of a decoded message.

Default: 4MB

source

pub fn max_encoding_message_size(self, limit: usize) -> Self

Limits the maximum size of an encoded message.

Default: usize::MAX

source

pub async fn get_service_account( &mut self, request: impl IntoRequest<GetServiceAccountRequest> ) -> Result<Response<ServiceAccount>, Status>

Retrieves the organizations service account, if it exists, otherwise it creates the organization service account. This API is idempotent and will only create a service account once. On subsequent calls it will return the previously created service account. SHA, SCC and CTD Infra Automation will use this SA. This SA will not have any permissions when created. The UI will provision this via IAM or the user will using their own internal process. This API only creates SAs on the organization. Folders are not supported and projects will use per-project SAs associated with APIs enabled on a project. This API will be called by the UX onboarding workflow.

source

pub async fn get_settings( &mut self, request: impl IntoRequest<GetSettingsRequest> ) -> Result<Response<Settings>, Status>

Gets the Settings.

source

pub async fn update_settings( &mut self, request: impl IntoRequest<UpdateSettingsRequest> ) -> Result<Response<Settings>, Status>

Updates the Settings.

source

pub async fn reset_settings( &mut self, request: impl IntoRequest<ResetSettingsRequest> ) -> Result<Response<()>, Status>

Reset the organization, folder or project’s settings and return the settings of just that resource to the default.

Settings are present at the organization, folder, project, and cluster levels. Using Reset on a sub-organization level will remove that resource’s override and result in the parent’s settings being used (eg: if Reset on a cluster, project settings will be used).

Using Reset on organization will remove the override that was set and result in default settings being used.

source

pub async fn batch_get_settings( &mut self, request: impl IntoRequest<BatchGetSettingsRequest> ) -> Result<Response<BatchGetSettingsResponse>, Status>

Gets a list of settings.

source

pub async fn calculate_effective_settings( &mut self, request: impl IntoRequest<CalculateEffectiveSettingsRequest> ) -> Result<Response<Settings>, Status>

CalculateEffectiveSettings looks up all of the Security Center Settings resources in the GCP resource hierarchy, and calculates the effective settings on that resource by applying the following rules:

  • Settings provided closer to the target resource take precedence over those further away (e.g. folder will override organization level settings).
  • Product defaults can be overridden at org, folder, project, and cluster levels.
  • Detectors will be filtered out if they belong to a billing tier the customer has not configured.
source

pub async fn batch_calculate_effective_settings( &mut self, request: impl IntoRequest<BatchCalculateEffectiveSettingsRequest> ) -> Result<Response<BatchCalculateEffectiveSettingsResponse>, Status>

Gets a list of effective settings.

source

pub async fn get_component_settings( &mut self, request: impl IntoRequest<GetComponentSettingsRequest> ) -> Result<Response<ComponentSettings>, Status>

Gets the Component Settings.

source

pub async fn update_component_settings( &mut self, request: impl IntoRequest<UpdateComponentSettingsRequest> ) -> Result<Response<ComponentSettings>, Status>

Updates the Component Settings.

source

pub async fn reset_component_settings( &mut self, request: impl IntoRequest<ResetComponentSettingsRequest> ) -> Result<Response<()>, Status>

Reset the organization, folder or project’s component settings and return the settings to the default. Settings are present at the organization, folder and project levels. Using Reset for a folder or project will remove the override that was set and result in the organization-level settings being used.

source

pub async fn calculate_effective_component_settings( &mut self, request: impl IntoRequest<CalculateEffectiveComponentSettingsRequest> ) -> Result<Response<ComponentSettings>, Status>

Gets the Effective Component Settings.

source

pub async fn list_detectors( &mut self, request: impl IntoRequest<ListDetectorsRequest> ) -> Result<Response<ListDetectorsResponse>, Status>

Retrieves an unordered list of available detectors.

source

pub async fn list_components( &mut self, request: impl IntoRequest<ListComponentsRequest> ) -> Result<Response<ListComponentsResponse>, Status>

Retrieves an unordered list of available SCC components.

Trait Implementations§

source§

impl<T: Clone> Clone for SecurityCenterSettingsServiceClient<T>

source§

fn clone(&self) -> SecurityCenterSettingsServiceClient<T>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<T: Debug> Debug for SecurityCenterSettingsServiceClient<T>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> FromRef<T> for T
where T: Clone,

§

fn from_ref(input: &T) -> T

Converts to this type from a reference to the input type.
§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

Wrap the input message T in a tonic::Request
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more