googleapis
Version:
Google APIs Client Library for Node.js
832 lines • 160 kB
TypeScript
/// <reference types="node" />
import { OAuth2Client, JWT, Compute, UserRefreshClient, BaseExternalAccountClient, GaxiosPromise, GoogleConfigurable, MethodOptions, StreamMethodOptions, GlobalOptions, GoogleAuth, BodyResponseCallback, APIRequestContext } from 'googleapis-common';
import { Readable } from 'stream';
export declare namespace securitycenter_v1beta1 {
export interface Options extends GlobalOptions {
version: 'v1beta1';
}
interface StandardParameters {
/**
* Auth client or API Key for the request
*/
auth?: string | OAuth2Client | JWT | Compute | UserRefreshClient | BaseExternalAccountClient | GoogleAuth;
/**
* V1 error format.
*/
'$.xgafv'?: string;
/**
* OAuth access token.
*/
access_token?: string;
/**
* Data format for response.
*/
alt?: string;
/**
* JSONP
*/
callback?: string;
/**
* Selector specifying which fields to include in a partial response.
*/
fields?: string;
/**
* API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
*/
key?: string;
/**
* OAuth 2.0 token for the current user.
*/
oauth_token?: string;
/**
* Returns response with indentations and line breaks.
*/
prettyPrint?: boolean;
/**
* Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
*/
quotaUser?: string;
/**
* Legacy upload protocol for media (e.g. "media", "multipart").
*/
uploadType?: string;
/**
* Upload protocol for media (e.g. "raw", "multipart").
*/
upload_protocol?: string;
}
/**
* Security Command Center API
*
* Security Command Center API provides access to temporal views of assets and findings within an organization.
*
* @example
* ```js
* const {google} = require('googleapis');
* const securitycenter = google.securitycenter('v1beta1');
* ```
*/
export class Securitycenter {
context: APIRequestContext;
organizations: Resource$Organizations;
constructor(options: GlobalOptions, google?: GoogleConfigurable);
}
/**
* Security Command Center representation of a Google Cloud resource. The Asset is a Security Command Center resource that captures information about a single Google Cloud resource. All modifications to an Asset are only within the context of Security Command Center and don't affect the referenced Google Cloud resource.
*/
export interface Schema$Asset {
/**
* The time at which the asset was created in Security Command Center.
*/
createTime?: string | null;
/**
* The relative resource name of this asset. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Example: "organizations/{organization_id\}/assets/{asset_id\}".
*/
name?: string | null;
/**
* Resource managed properties. These properties are managed and defined by the Google Cloud resource and cannot be modified by the user.
*/
resourceProperties?: {
[key: string]: any;
} | null;
/**
* Security Command Center managed properties. These properties are managed by Security Command Center and cannot be modified by the user.
*/
securityCenterProperties?: Schema$SecurityCenterProperties;
/**
* User specified security marks. These marks are entirely managed by the user and come from the SecurityMarks resource that belongs to the asset.
*/
securityMarks?: Schema$GoogleCloudSecuritycenterV1beta1SecurityMarks;
/**
* The time at which the asset was last updated, added, or deleted in Security Command Center.
*/
updateTime?: string | null;
}
/**
* The configuration used for Asset Discovery runs.
*/
export interface Schema$AssetDiscoveryConfig {
/**
* The mode to use for filtering asset discovery.
*/
inclusionMode?: string | null;
/**
* The project ids to use for filtering asset discovery.
*/
projectIds?: string[] | null;
}
/**
* Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { "audit_configs": [ { "service": "allServices", "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] \}, { "log_type": "DATA_WRITE" \}, { "log_type": "ADMIN_READ" \} ] \}, { "service": "sampleservice.googleapis.com", "audit_log_configs": [ { "log_type": "DATA_READ" \}, { "log_type": "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] \} ] \} ] \} For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts jose@example.com from DATA_READ logging, and aliya@example.com from DATA_WRITE logging.
*/
export interface Schema$AuditConfig {
/**
* The configuration for logging of each type of permission.
*/
auditLogConfigs?: Schema$AuditLogConfig[];
/**
* Specifies a service that will be enabled for audit logging. For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices` is a special value that covers all services.
*/
service?: string | null;
}
/**
* Provides the configuration for logging a type of permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [ "user:jose@example.com" ] \}, { "log_type": "DATA_WRITE" \} ] \} This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ logging.
*/
export interface Schema$AuditLogConfig {
/**
* Specifies the identities that do not cause logging for this type of permission. Follows the same format of Binding.members.
*/
exemptedMembers?: string[] | null;
/**
* The log type that this config enables.
*/
logType?: string | null;
}
/**
* Associates `members` with a `role`.
*/
export interface Schema$Binding {
/**
* The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the members in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
*/
condition?: Schema$Expr;
/**
* Specifies the identities requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid\}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid\}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid\}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid\}?uid={uniqueid\}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid\}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid\}?uid={uniqueid\}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid\}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid\}?uid={uniqueid\}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid\}` and the recovered group retains the role in the binding. * `domain:{domain\}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`.
*/
members?: string[] | null;
/**
* Role that is assigned to `members`. For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
*/
role?: string | null;
}
/**
* The request message for Operations.CancelOperation.
*/
export interface Schema$CancelOperationRequest {
}
/**
* A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); \} The JSON representation for `Empty` is empty JSON object `{\}`.
*/
export interface Schema$Empty {
}
/**
* Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: "Summary size limit" description: "Determines if a summary is less than 100 chars" expression: "document.summary.size() < 100" Example (Equality): title: "Requestor is owner" description: "Determines if requestor is the document owner" expression: "document.owner == request.auth.claims.email" Example (Logic): title: "Public documents" description: "Determine whether the document should be publicly visible" expression: "document.type != 'private' && document.type != 'internal'" Example (Data Manipulation): title: "Notification string" description: "Create a notification string with a timestamp." expression: "'New message received at ' + string(document.create_time)" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information.
*/
export interface Schema$Expr {
/**
* Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.
*/
description?: string | null;
/**
* Textual representation of an expression in Common Expression Language syntax.
*/
expression?: string | null;
/**
* Optional. String indicating the location of the expression for error reporting, e.g. a file name and a position in the file.
*/
location?: string | null;
/**
* Optional. Title for the expression, i.e. a short string describing its purpose. This can be used e.g. in UIs which allow to enter the expression.
*/
title?: string | null;
}
/**
* Security Command Center finding. A finding is a record of assessment data like security, risk, health, or privacy, that is ingested into Security Command Center for presentation, notification, analysis, policy testing, and enforcement. For example, a cross-site scripting (XSS) vulnerability in an App Engine application is a finding.
*/
export interface Schema$Finding {
/**
* The additional taxonomy group within findings from a given source. This field is immutable after creation time. Example: "XSS_FLASH_INJECTION"
*/
category?: string | null;
/**
* The time at which the finding was created in Security Command Center.
*/
createTime?: string | null;
/**
* The time at which the event took place, or when an update to the finding occurred. For example, if the finding represents an open firewall it would capture the time the detector believes the firewall became open. The accuracy is determined by the detector. If the finding were to be resolved afterward, this time would reflect when the finding was resolved.
*/
eventTime?: string | null;
/**
* The URI that, if available, points to a web page outside of Security Command Center where additional information about the finding can be found. This field is guaranteed to be either empty or a well formed URL.
*/
externalUri?: string | null;
/**
* The relative resource name of this finding. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Example: "organizations/{organization_id\}/sources/{source_id\}/findings/{finding_id\}"
*/
name?: string | null;
/**
* The relative resource name of the source the finding belongs to. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name This field is immutable after creation time. For example: "organizations/{organization_id\}/sources/{source_id\}"
*/
parent?: string | null;
/**
* For findings on Google Cloud resources, the full resource name of the Google Cloud resource this finding is for. See: https://cloud.google.com/apis/design/resource_names#full_resource_name When the finding is for a non-Google Cloud resource, the resourceName can be a customer or partner defined string. This field is immutable after creation time.
*/
resourceName?: string | null;
/**
* Output only. User specified security marks. These marks are entirely managed by the user and come from the SecurityMarks resource that belongs to the finding.
*/
securityMarks?: Schema$SecurityMarks;
/**
* The severity of the finding. This field is managed by the source that writes the finding.
*/
severity?: string | null;
/**
* Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.
*/
sourceProperties?: {
[key: string]: any;
} | null;
/**
* The state of the finding.
*/
state?: string | null;
}
/**
* Message that contains the resource name and display name of a folder resource.
*/
export interface Schema$Folder {
/**
* Full resource name of this folder. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
resourceFolder?: string | null;
/**
* The user defined display name for this folder.
*/
resourceFolderDisplayName?: string | null;
}
/**
* Request message for `GetIamPolicy` method.
*/
export interface Schema$GetIamPolicyRequest {
/**
* OPTIONAL: A `GetPolicyOptions` object for specifying options to `GetIamPolicy`.
*/
options?: Schema$GetPolicyOptions;
}
/**
* Encapsulates settings provided to GetIamPolicy.
*/
export interface Schema$GetPolicyOptions {
/**
* Optional. The policy format version to be returned. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional bindings must specify version 3. Policies without any conditional bindings may specify any valid value or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
*/
requestedPolicyVersion?: number | null;
}
/**
* Security Command Center finding. A finding is a record of assessment data (security, risk, health or privacy) ingested into Security Command Center for presentation, notification, analysis, policy testing, and enforcement. For example, an XSS vulnerability in an App Engine application is a finding.
*/
export interface Schema$GoogleCloudSecuritycenterV1beta1Finding {
/**
* The additional taxonomy group within findings from a given source. This field is immutable after creation time. Example: "XSS_FLASH_INJECTION"
*/
category?: string | null;
/**
* The time at which the finding was created in Security Command Center.
*/
createTime?: string | null;
/**
* The time at which the event took place, or when an update to the finding occurred. For example, if the finding represents an open firewall it would capture the time the detector believes the firewall became open. The accuracy is determined by the detector. If the finding were to be resolved afterward, this time would reflect when the finding was resolved.
*/
eventTime?: string | null;
/**
* The URI that, if available, points to a web page outside of Security Command Center where additional information about the finding can be found. This field is guaranteed to be either empty or a well formed URL.
*/
externalUri?: string | null;
/**
* The relative resource name of this finding. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Example: "organizations/{organization_id\}/sources/{source_id\}/findings/{finding_id\}"
*/
name?: string | null;
/**
* Immutable. The relative resource name of the source the finding belongs to. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name This field is immutable after creation time. For example: "organizations/{organization_id\}/sources/{source_id\}"
*/
parent?: string | null;
/**
* For findings on Google Cloud resources, the full resource name of the Google Cloud resource this finding is for. See: https://cloud.google.com/apis/design/resource_names#full_resource_name When the finding is for a non-Google Cloud resource, the resourceName can be a customer or partner defined string. This field is immutable after creation time.
*/
resourceName?: string | null;
/**
* Output only. User specified security marks. These marks are entirely managed by the user and come from the SecurityMarks resource that belongs to the finding.
*/
securityMarks?: Schema$GoogleCloudSecuritycenterV1beta1SecurityMarks;
/**
* Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.
*/
sourceProperties?: {
[key: string]: any;
} | null;
/**
* The state of the finding.
*/
state?: string | null;
}
/**
* Response of asset discovery run
*/
export interface Schema$GoogleCloudSecuritycenterV1beta1RunAssetDiscoveryResponse {
/**
* The duration between asset discovery run start and end
*/
duration?: string | null;
/**
* The state of an asset discovery run.
*/
state?: string | null;
}
/**
* User specified security marks that are attached to the parent Security Command Center resource. Security marks are scoped within a Security Command Center organization -- they can be modified and viewed by all users who have proper permissions on the organization.
*/
export interface Schema$GoogleCloudSecuritycenterV1beta1SecurityMarks {
/**
* Mutable user specified security marks belonging to the parent resource. Constraints are as follows: * Keys and values are treated as case insensitive * Keys must be between 1 - 256 characters (inclusive) * Keys must be letters, numbers, underscores, or dashes * Values have leading and trailing whitespace trimmed, remaining characters must be between 1 - 4096 characters (inclusive)
*/
marks?: {
[key: string]: string;
} | null;
/**
* The relative resource name of the SecurityMarks. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Examples: "organizations/{organization_id\}/assets/{asset_id\}/securityMarks" "organizations/{organization_id\}/sources/{source_id\}/findings/{finding_id\}/securityMarks".
*/
name?: string | null;
}
/**
* Cloud SCC's Notification
*/
export interface Schema$GoogleCloudSecuritycenterV1NotificationMessage {
/**
* If it's a Finding based notification config, this field will be populated.
*/
finding?: Schema$Finding;
/**
* Name of the notification config that generated current notification.
*/
notificationConfigName?: string | null;
/**
* The Cloud resource tied to this notification's Finding.
*/
resource?: Schema$GoogleCloudSecuritycenterV1Resource;
}
/**
* Security Command Center finding. A finding is a record of assessment data (security, risk, health or privacy) ingested into Security Command Center for presentation, notification, analysis, policy testing, and enforcement. For example, an XSS vulnerability in an App Engine application is a finding.
*/
export interface Schema$GoogleCloudSecuritycenterV1p1beta1Finding {
/**
* The additional taxonomy group within findings from a given source. This field is immutable after creation time. Example: "XSS_FLASH_INJECTION"
*/
category?: string | null;
/**
* The time at which the finding was created in Security Command Center.
*/
createTime?: string | null;
/**
* The time at which the event took place, or when an update to the finding occurred. For example, if the finding represents an open firewall it would capture the time the detector believes the firewall became open. The accuracy is determined by the detector. If the finding were to be resolved afterward, this time would reflect when the finding was resolved.
*/
eventTime?: string | null;
/**
* The URI that, if available, points to a web page outside of Security Command Center where additional information about the finding can be found. This field is guaranteed to be either empty or a well formed URL.
*/
externalUri?: string | null;
/**
* The relative resource name of this finding. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Example: "organizations/{organization_id\}/sources/{source_id\}/findings/{finding_id\}"
*/
name?: string | null;
/**
* The relative resource name of the source the finding belongs to. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name This field is immutable after creation time. For example: "organizations/{organization_id\}/sources/{source_id\}"
*/
parent?: string | null;
/**
* For findings on Google Cloud resources, the full resource name of the Google Cloud resource this finding is for. See: https://cloud.google.com/apis/design/resource_names#full_resource_name When the finding is for a non-Google Cloud resource, the resourceName can be a customer or partner defined string. This field is immutable after creation time.
*/
resourceName?: string | null;
/**
* Output only. User specified security marks. These marks are entirely managed by the user and come from the SecurityMarks resource that belongs to the finding.
*/
securityMarks?: Schema$GoogleCloudSecuritycenterV1p1beta1SecurityMarks;
/**
* The severity of the finding. This field is managed by the source that writes the finding.
*/
severity?: string | null;
/**
* Source specific properties. These properties are managed by the source that writes the finding. The key names in the source_properties map must be between 1 and 255 characters, and must start with a letter and contain alphanumeric characters or underscores only.
*/
sourceProperties?: {
[key: string]: any;
} | null;
/**
* The state of the finding.
*/
state?: string | null;
}
/**
* Message that contains the resource name and display name of a folder resource.
*/
export interface Schema$GoogleCloudSecuritycenterV1p1beta1Folder {
/**
* Full resource name of this folder. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
resourceFolder?: string | null;
/**
* The user defined display name for this folder.
*/
resourceFolderDisplayName?: string | null;
}
/**
* Security Command Center's Notification
*/
export interface Schema$GoogleCloudSecuritycenterV1p1beta1NotificationMessage {
/**
* If it's a Finding based notification config, this field will be populated.
*/
finding?: Schema$GoogleCloudSecuritycenterV1p1beta1Finding;
/**
* Name of the notification config that generated current notification.
*/
notificationConfigName?: string | null;
/**
* The Cloud resource tied to the notification.
*/
resource?: Schema$GoogleCloudSecuritycenterV1p1beta1Resource;
}
/**
* Information related to the Google Cloud resource.
*/
export interface Schema$GoogleCloudSecuritycenterV1p1beta1Resource {
/**
* Output only. Contains a Folder message for each folder in the assets ancestry. The first folder is the deepest nested folder, and the last folder is the folder directly under the Organization.
*/
folders?: Schema$GoogleCloudSecuritycenterV1p1beta1Folder[];
/**
* The full resource name of the resource. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
name?: string | null;
/**
* The full resource name of resource's parent.
*/
parent?: string | null;
/**
* The human readable name of resource's parent.
*/
parentDisplayName?: string | null;
/**
* The full resource name of project that the resource belongs to.
*/
project?: string | null;
/**
* The human readable name of project that the resource belongs to.
*/
projectDisplayName?: string | null;
}
/**
* Response of asset discovery run
*/
export interface Schema$GoogleCloudSecuritycenterV1p1beta1RunAssetDiscoveryResponse {
/**
* The duration between asset discovery run start and end
*/
duration?: string | null;
/**
* The state of an asset discovery run.
*/
state?: string | null;
}
/**
* User specified security marks that are attached to the parent Security Command Center resource. Security marks are scoped within a Security Command Center organization -- they can be modified and viewed by all users who have proper permissions on the organization.
*/
export interface Schema$GoogleCloudSecuritycenterV1p1beta1SecurityMarks {
/**
* Mutable user specified security marks belonging to the parent resource. Constraints are as follows: * Keys and values are treated as case insensitive * Keys must be between 1 - 256 characters (inclusive) * Keys must be letters, numbers, underscores, or dashes * Values have leading and trailing whitespace trimmed, remaining characters must be between 1 - 4096 characters (inclusive)
*/
marks?: {
[key: string]: string;
} | null;
/**
* The relative resource name of the SecurityMarks. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Examples: "organizations/{organization_id\}/assets/{asset_id\}/securityMarks" "organizations/{organization_id\}/sources/{source_id\}/findings/{finding_id\}/securityMarks".
*/
name?: string | null;
}
/**
* Information related to the Google Cloud resource.
*/
export interface Schema$GoogleCloudSecuritycenterV1Resource {
/**
* Output only. Contains a Folder message for each folder in the assets ancestry. The first folder is the deepest nested folder, and the last folder is the folder directly under the Organization.
*/
folders?: Schema$Folder[];
/**
* The full resource name of the resource. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
name?: string | null;
/**
* The full resource name of resource's parent.
*/
parent?: string | null;
/**
* The human readable name of resource's parent.
*/
parentDisplayName?: string | null;
/**
* The full resource name of project that the resource belongs to.
*/
project?: string | null;
/**
* The human readable name of project that the resource belongs to.
*/
projectDisplayName?: string | null;
}
/**
* Response of asset discovery run
*/
export interface Schema$GoogleCloudSecuritycenterV1RunAssetDiscoveryResponse {
/**
* The duration between asset discovery run start and end
*/
duration?: string | null;
/**
* The state of an asset discovery run.
*/
state?: string | null;
}
/**
* Request message for grouping by assets.
*/
export interface Schema$GroupAssetsRequest {
/**
* When compare_duration is set, the Asset's "state" property is updated to indicate whether the asset was added, removed, or remained present during the compare_duration period of time that precedes the read_time. This is the time between (read_time - compare_duration) and read_time. The state value is derived based on the presence of the asset at the two points in time. Intermediate state changes between the two times don't affect the result. For example, the results aren't affected if the asset is removed and re-created again. Possible "state" values when compare_duration is specified: * "ADDED": indicates that the asset was not present before compare_duration, but present at reference_time. * "REMOVED": indicates that the asset was present at the start of compare_duration, but not present at reference_time. * "ACTIVE": indicates that the asset was present at both the start and the end of the time period defined by compare_duration and reference_time. This field is ignored if `state` is not a field in `group_by`.
*/
compareDuration?: string | null;
/**
* Expression that defines the filter to apply across assets. The expression is a list of zero or more restrictions combined via logical operators `AND` and `OR`. Parentheses are not supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. The fields map to those defined in the Asset resource. Examples include: * name * security_center_properties.resource_name * resource_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `\>`, `<`, `\>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. For example, `resource_properties.size = 100` is a valid filter string.
*/
filter?: string | null;
/**
* Required. Expression that defines what assets fields to use for grouping. The string value should follow SQL syntax: comma separated list of fields. For example: "security_center_properties.resource_project,security_center_properties.project". The following fields are supported when compare_duration is not set: * security_center_properties.resource_project * security_center_properties.resource_type * security_center_properties.resource_parent The following fields are supported when compare_duration is set: * security_center_properties.resource_type
*/
groupBy?: string | null;
/**
* The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000.
*/
pageSize?: number | null;
/**
* The value returned by the last `GroupAssetsResponse`; indicates that this is a continuation of a prior `GroupAssets` call, and that the system should return the next page of data.
*/
pageToken?: string | null;
/**
* Time used as a reference point when filtering assets. The filter is limited to assets existing at the supplied time and their values are those at that specific time. Absence of this field will default to the API's version of NOW.
*/
readTime?: string | null;
}
/**
* Response message for grouping by assets.
*/
export interface Schema$GroupAssetsResponse {
/**
* Group results. There exists an element for each existing unique combination of property/values. The element contains a count for the number of times those specific property/values appear.
*/
groupByResults?: Schema$GroupResult[];
/**
* Token to retrieve the next page of results, or empty if there are no more results.
*/
nextPageToken?: string | null;
/**
* Time used for executing the groupBy request.
*/
readTime?: string | null;
}
/**
* Request message for grouping by findings.
*/
export interface Schema$GroupFindingsRequest {
/**
* Expression that defines the filter to apply across findings. The expression is a list of one or more restrictions combined via logical operators `AND` and `OR`. Parentheses are not supported, and `OR` has higher precedence than `AND`. Restrictions have the form ` ` and may have a `-` character in front of them to indicate negation. Examples include: * name * source_properties.a_property * security_marks.marks.marka The supported operators are: * `=` for all value types. * `\>`, `<`, `\>=`, `<=` for integer values. * `:`, meaning substring matching, for strings. The supported value types are: * string literals in quotes. * integer literals without quotes. * boolean literals `true` and `false` without quotes. For example, `source_properties.size = 100` is a valid filter string.
*/
filter?: string | null;
/**
* Required. Expression that defines what assets fields to use for grouping (including `state`). The string value should follow SQL syntax: comma separated list of fields. For example: "parent,resource_name". The following fields are supported: * resource_name * category * state * parent
*/
groupBy?: string | null;
/**
* The maximum number of results to return in a single response. Default is 10, minimum is 1, maximum is 1000.
*/
pageSize?: number | null;
/**
* The value returned by the last `GroupFindingsResponse`; indicates that this is a continuation of a prior `GroupFindings` call, and that the system should return the next page of data.
*/
pageToken?: string | null;
/**
* Time used as a reference point when filtering findings. The filter is limited to findings existing at the supplied time and their values are those at that specific time. Absence of this field will default to the API's version of NOW.
*/
readTime?: string | null;
}
/**
* Response message for group by findings.
*/
export interface Schema$GroupFindingsResponse {
/**
* Group results. There exists an element for each existing unique combination of property/values. The element contains a count for the number of times those specific property/values appear.
*/
groupByResults?: Schema$GroupResult[];
/**
* Token to retrieve the next page of results, or empty if there are no more results.
*/
nextPageToken?: string | null;
/**
* Time used for executing the groupBy request.
*/
readTime?: string | null;
}
/**
* Result containing the properties and count of a groupBy request.
*/
export interface Schema$GroupResult {
/**
* Total count of resources for the given properties.
*/
count?: string | null;
/**
* Properties matching the groupBy fields in the request.
*/
properties?: {
[key: string]: any;
} | null;
}
/**
* Response message for listing assets.
*/
export interface Schema$ListAssetsResponse {
/**
* Assets matching the list request.
*/
listAssetsResults?: Schema$ListAssetsResult[];
/**
* Token to retrieve the next page of results, or empty if there are no more results.
*/
nextPageToken?: string | null;
/**
* Time used for executing the list request.
*/
readTime?: string | null;
/**
* The total number of assets matching the query.
*/
totalSize?: number | null;
}
/**
* Result containing the Asset and its State.
*/
export interface Schema$ListAssetsResult {
/**
* Asset matching the search request.
*/
asset?: Schema$Asset;
/**
* State of the asset.
*/
state?: string | null;
}
/**
* Response message for listing findings.
*/
export interface Schema$ListFindingsResponse {
/**
* Findings matching the list request.
*/
findings?: Schema$GoogleCloudSecuritycenterV1beta1Finding[];
/**
* Token to retrieve the next page of results, or empty if there are no more results.
*/
nextPageToken?: string | null;
/**
* Time used for executing the list request.
*/
readTime?: string | null;
/**
* The total number of findings matching the query.
*/
totalSize?: number | null;
}
/**
* The response message for Operations.ListOperations.
*/
export interface Schema$ListOperationsResponse {
/**
* The standard List next-page token.
*/
nextPageToken?: string | null;
/**
* A list of operations that matches the specified filter in the request.
*/
operations?: Schema$Operation[];
}
/**
* Response message for listing sources.
*/
export interface Schema$ListSourcesResponse {
/**
* Token to retrieve the next page of results, or empty if there are no more results.
*/
nextPageToken?: string | null;
/**
* Sources belonging to the requested parent.
*/
sources?: Schema$Source[];
}
/**
* This resource represents a long-running operation that is the result of a network API call.
*/
export interface Schema$Operation {
/**
* If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
*/
done?: boolean | null;
/**
* The error result of the operation in case of failure or cancellation.
*/
error?: Schema$Status;
/**
* Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
*/
metadata?: {
[key: string]: any;
} | null;
/**
* The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id\}`.
*/
name?: string | null;
/**
* The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
*/
response?: {
[key: string]: any;
} | null;
}
/**
* User specified settings that are attached to the Security Command Center organization.
*/
export interface Schema$OrganizationSettings {
/**
* The configuration used for Asset Discovery runs.
*/
assetDiscoveryConfig?: Schema$AssetDiscoveryConfig;
/**
* A flag that indicates if Asset Discovery should be enabled. If the flag is set to `true`, then discovery of assets will occur. If it is set to `false, all historical assets will remain, but discovery of future assets will not occur.
*/
enableAssetDiscovery?: boolean | null;
/**
* The relative resource name of the settings. See: https://cloud.google.com/apis/design/resource_names#relative_resource_name Example: "organizations/{organization_id\}/organizationSettings".
*/
name?: string | null;
}
/**
* An Identity and Access Management (IAM) policy, which specifies access controls for Google Cloud resources. A `Policy` is a collection of `bindings`. A `binding` binds one or more `members` to a single `role`. Members can be user accounts, service accounts, Google groups, and domains (such as G Suite). A `role` is a named list of permissions; each `role` can be an IAM predefined role or a user-created custom role. For some types of Google Cloud resources, a `binding` can also specify a `condition`, which is a logical expression that allows access to a resource only if the expression evaluates to `true`. A condition can add constraints based on attributes of the request, the resource, or both. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). **JSON example:** { "bindings": [ { "role": "roles/resourcemanager.organizationAdmin", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] \}, { "role": "roles/resourcemanager.organizationViewer", "members": [ "user:eve@example.com" ], "condition": { "title": "expirable access", "description": "Does not grant access after Sep 2020", "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", \} \} ], "etag": "BwWWja0YfJA=", "version": 3 \} **YAML example:** bindings: - members: - user:mike@example.com - group:admins@example.com - domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com role: roles/resourcemanager.organizationAdmin - members: - user:eve@example.com role: roles/resourcemanager.organizationViewer condition: title: expirable access description: Does not grant access after Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z') - etag: BwWWja0YfJA= - version: 3 For a description of IAM and its features, see the [IAM documentation](https://cloud.google.com/iam/docs/).
*/
export interface Schema$Policy {
/**
* Specifies cloud audit logging configuration for this policy.
*/
auditConfigs?: Schema$AuditConfig[];
/**
* Associates a list of `members` to a `role`. Optionally, may specify a `condition` that determines how and when the `bindings` are applied. Each of the `bindings` must contain at least one member.
*/
bindings?: Schema$Binding[];
/**
* `etag` is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the `etag` in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An `etag` is returned in the response to `getIamPolicy`, and systems are expected to put that etag in the request to `setIamPolicy` to ensure that their change will be applied to the same version of the policy. **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost.
*/
etag?: string | null;
/**
* Specifies the format of the policy. Valid values are `0`, `1`, and `3`. Requests that specify an invalid value are rejected. Any operation that affects conditional role bindings must specify version `3`. This requirement applies to the following operations: * Getting a policy that includes a conditional role binding * Adding a conditional role binding to a policy * Changing a conditional role binding in a policy * Removing any role binding, with or without a condition, from a policy that includes conditions **Important:** If you use IAM Conditions, you must include the `etag` field whenever you call `setIamPolicy`. If you omit this field, then IAM allows you to overwrite a version `3` policy with a version `1` policy, and all of the conditions in the version `3` policy are lost. If a policy does not include any conditions, operations on that policy may specify any valid version or leave the field unset. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
*/
version?: number | null;
}
/**
* Request message for running asset discovery for an organization.
*/
export interface Schema$RunAssetDiscoveryRequest {
}
/**
* Security Command Center managed properties. These properties are managed by Security Command Center and cannot be modified by the user.
*/
export interface Schema$SecurityCenterProperties {
/**
* Immutable. The full resource name of the Google Cloud resource this asset represents. This field is immutable after create time. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
resourceName?: string | null;
/**
* Owners of the Google Cloud resource.
*/
resourceOwners?: string[] | null;
/**
* The full resource name of the immediate parent of the resource. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
resourceParent?: string | null;
/**
* The full resource name of the project the resource belongs to. See: https://cloud.google.com/apis/design/resource_names#full_resource_name
*/
resourceProject?: string | null;
/**
* The type of the Google Cloud resource. Examples include: APPLICATION, PROJECT, and ORGANIZATION. This is a case insensitive field defined by Security Command Center and/or the producer of the resource and is immutable after create time.
*/
resourceType?: string | null;
}
/**
* User specified security marks that are attached to the parent Security Command Center resource. Security marks are scoped within a Security Command Center organization -- they can be modified and viewed by all users who have proper permissions on the organization.
*/
export interface Schema$SecurityMarks {
/**
* Mutable user specified security marks belonging to the parent resource. Constraints are as follows: * Keys and values are treated as case insensitive * Keys must be between 1 - 256 characters (inclusive) * Keys must be lette