UNPKG

googleapis

Version:
1,174 lines 166 kB
/// <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 containeranalysis_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; } /** * Container Analysis API * * An implementation of the Grafeas API, which stores, and enables querying and retrieval of critical metadata about all of your software artifacts. * * @example * ```js * const {google} = require('googleapis'); * const containeranalysis = google.containeranalysis('v1beta1'); * ``` */ export class Containeranalysis { context: APIRequestContext; projects: Resource$Projects; constructor(options: GlobalOptions, google?: GoogleConfigurable); } /** * An alias to a repo revision. */ export interface Schema$AliasContext { /** * The alias kind. */ kind?: string | null; /** * The alias name. */ name?: string | null; } /** * Artifact describes a build product. */ export interface Schema$Artifact { /** * Hash or checksum value of a binary, or Docker Registry 2.0 digest of a container. */ checksum?: string | null; /** * Artifact ID, if any; for container images, this will be a URL by digest like `gcr.io/projectID/imagename@sha256:123456`. */ id?: string | null; /** * Related artifact names. This may be the path to a binary or jar file, or in the case of a container build, the name used to push the container image to Google Container Registry, as presented to `docker push`. Note that a single Artifact ID can have multiple names, for example if two tags are applied to one image. */ names?: string[] | null; } /** * Defines a hash object for use in Materials and Products. */ export interface Schema$ArtifactHashes { sha256?: string | null; } /** * Defines an object to declare an in-toto artifact rule */ export interface Schema$ArtifactRule { artifactRule?: string[] | null; } /** * Occurrence that represents a single "attestation". The authenticity of an attestation can be verified using the attached signature. If the verifier trusts the public key of the signer, then verifying the signature is sufficient to establish trust. In this circumstance, the authority to which this attestation is attached is primarily useful for look-up (how to find this attestation if you already know the authority and artifact to be verified) and intent (which authority was this attestation intended to sign for). */ export interface Schema$Attestation { genericSignedAttestation?: Schema$GenericSignedAttestation; /** * A PGP signed attestation. */ pgpSignedAttestation?: Schema$PgpSignedAttestation; } /** * Note kind that represents a logical attestation "role" or "authority". For example, an organization might have one `Authority` for "QA" and one for "build". This note is intended to act strictly as a grouping mechanism for the attached occurrences (Attestations). This grouping mechanism also provides a security boundary, since IAM ACLs gate the ability for a principle to attach an occurrence to a given note. It also provides a single point of lookup to find all attached attestation occurrences, even if they don't all live in the same project. */ export interface Schema$Authority { /** * Hint hints at the purpose of the attestation authority. */ hint?: Schema$Hint; } /** * Basis describes the base image portion (Note) of the DockerImage relationship. Linked occurrences are derived from this or an equivalent image via: FROM Or an equivalent reference, e.g. a tag of the resource_url. */ export interface Schema$Basis { /** * Required. Immutable. The fingerprint of the base image. */ fingerprint?: Schema$Fingerprint; /** * Required. Immutable. The resource_url for the resource representing the basis of associated occurrence images. */ resourceUrl?: string | null; } /** * Request to create notes in batch. */ export interface Schema$BatchCreateNotesRequest { /** * Required. The notes to create, the key is expected to be the note ID. Max allowed length is 1000. */ notes?: { [key: string]: Schema$Note; } | null; } /** * Response for creating notes in batch. */ export interface Schema$BatchCreateNotesResponse { /** * The notes that were created. */ notes?: Schema$Note[]; } /** * Request to create occurrences in batch. */ export interface Schema$BatchCreateOccurrencesRequest { /** * Required. The occurrences to create. Max allowed length is 1000. */ occurrences?: Schema$Occurrence[]; } /** * Response for creating occurrences in batch. */ export interface Schema$BatchCreateOccurrencesResponse { /** * The occurrences that were created. */ occurrences?: Schema$Occurrence[]; } /** * 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; } /** * Note holding the version of the provider's builder and the signature of the provenance message in the build details occurrence. */ export interface Schema$Build { /** * Required. Immutable. Version of the builder which produced this build. */ builderVersion?: string | null; /** * Signature of the build in occurrences pointing to this build note containing build details. */ signature?: Schema$BuildSignature; } /** * Provenance of a build. Contains all information needed to verify the full details about the build from source to completion. */ export interface Schema$BuildProvenance { /** * Version string of the builder at the time this build was executed. */ builderVersion?: string | null; /** * Special options applied to this build. This is a catch-all field where build providers can enter any desired additional details. */ buildOptions?: { [key: string]: string; } | null; /** * Output of the build. */ builtArtifacts?: Schema$Artifact[]; /** * Commands requested by the build. */ commands?: Schema$Command[]; /** * Time at which the build was created. */ createTime?: string | null; /** * E-mail address of the user who initiated this build. Note that this was the user's e-mail address at the time the build was initiated; this address may not represent the same end-user for all time. */ creator?: string | null; /** * Time at which execution of the build was finished. */ endTime?: string | null; /** * Required. Unique identifier of the build. */ id?: string | null; /** * URI where any logs for this provenance were written. */ logsUri?: string | null; /** * ID of the project. */ projectId?: string | null; /** * Details of the Source input to the build. */ sourceProvenance?: Schema$Source; /** * Time at which execution of the build was started. */ startTime?: string | null; /** * Trigger identifier if the build was triggered automatically; empty if not. */ triggerId?: string | null; } /** * Message encapsulating the signature of the verified build. */ export interface Schema$BuildSignature { /** * An ID for the key used to sign. This could be either an ID for the key stored in `public_key` (such as the ID or fingerprint for a PGP key, or the CN for a cert), or a reference to an external key (such as a reference to a key in Cloud Key Management Service). */ keyId?: string | null; /** * The type of the key, either stored in `public_key` or referenced in `key_id`. */ keyType?: string | null; /** * Public key of the builder which can be used to verify that the related findings are valid and unchanged. If `key_type` is empty, this defaults to PEM encoded public keys. This field may be empty if `key_id` references an external key. For Cloud Build based signatures, this is a PEM encoded public key. To verify the Cloud Build signature, place the contents of this field into a file (public.pem). The signature field is base64-decoded into its binary representation in signature.bin, and the provenance bytes from `BuildDetails` are base64-decoded into a binary representation in signed.bin. OpenSSL can then verify the signature: `openssl sha256 -verify public.pem -signature signature.bin signed.bin` */ publicKey?: string | null; /** * Required. Signature of the related `BuildProvenance`. In JSON, this is base-64 encoded. */ signature?: string | null; } /** * Defines an object for the byproducts field in in-toto links. The suggested fields are "stderr", "stdout", and "return-value". */ export interface Schema$ByProducts { customValues?: { [key: string]: string; } | null; } /** * A CloudRepoSourceContext denotes a particular revision in a Google Cloud Source Repo. */ export interface Schema$CloudRepoSourceContext { /** * An alias, which may be a branch or tag. */ aliasContext?: Schema$AliasContext; /** * The ID of the repo. */ repoId?: Schema$RepoId; /** * A revision ID. */ revisionId?: string | null; } /** * Command describes a step performed as part of the build pipeline. */ export interface Schema$Command { /** * Command-line arguments used when executing this command. */ args?: string[] | null; /** * Working directory (relative to project source root) used when running this command. */ dir?: string | null; /** * Environment variables set before running this command. */ env?: string[] | null; /** * Optional unique identifier for this command, used in wait_for to reference this command as a dependency. */ id?: string | null; /** * Required. Name of the command, as presented on the command line, or if the command is packaged as a Docker container, as presented to `docker pull`. */ name?: string | null; /** * The ID(s) of the command(s) that this command depends on. */ waitFor?: string[] | null; } /** * Common Vulnerability Scoring System version 3. For details, see https://www.first.org/cvss/specification-document */ export interface Schema$CVSSv3 { attackComplexity?: string | null; /** * Base Metrics Represents the intrinsic characteristics of a vulnerability that are constant over time and across user environments. */ attackVector?: string | null; availabilityImpact?: string | null; /** * The base score is a function of the base metric scores. */ baseScore?: number | null; confidentialityImpact?: string | null; exploitabilityScore?: number | null; impactScore?: number | null; integrityImpact?: string | null; privilegesRequired?: string | null; scope?: string | null; userInteraction?: string | null; } /** * An artifact that can be deployed in some runtime. */ export interface Schema$Deployable { /** * Required. Resource URI for the artifact being deployed. */ resourceUri?: string[] | null; } /** * The period during which some deployable was active in a runtime. */ export interface Schema$Deployment { /** * Address of the runtime element hosting this deployment. */ address?: string | null; /** * Configuration used to create this deployment. */ config?: string | null; /** * Required. Beginning of the lifetime of this deployment. */ deployTime?: string | null; /** * Platform hosting this deployment. */ platform?: string | null; /** * Output only. Resource URI for the artifact being deployed taken from the deployable field with the same name. */ resourceUri?: string[] | null; /** * End of the lifetime of this deployment. */ undeployTime?: string | null; /** * Identity of the user that triggered this deployment. */ userEmail?: string | null; } /** * Derived describes the derived image portion (Occurrence) of the DockerImage relationship. This image would be produced from a Dockerfile with FROM . */ export interface Schema$Derived { /** * Output only. This contains the base image URL for the derived image occurrence. */ baseResourceUrl?: string | null; /** * Output only. The number of layers by which this image differs from the associated image basis. */ distance?: number | null; /** * Required. The fingerprint of the derived image. */ fingerprint?: Schema$Fingerprint; /** * This contains layer-specific metadata, if populated it has length "distance" and is ordered with [distance] being the layer immediately following the base image and [1] being the final layer. */ layerInfo?: Schema$Layer[]; } /** * Identifies all appearances of this vulnerability in the package for a specific distro/location. For example: glibc in cpe:/o:debian:debian_linux:8 for versions 2.1 - 2.2 */ export interface Schema$Detail { /** * Required. The CPE URI in [cpe format](https://cpe.mitre.org/specification/) in which the vulnerability manifests. Examples include distro or storage location for vulnerable jar. */ cpeUri?: string | null; /** * A vendor-specific description of this note. */ description?: string | null; /** * The fix for this specific package version. */ fixedLocation?: Schema$VulnerabilityLocation; /** * Whether this detail is obsolete. Occurrences are expected not to point to obsolete details. */ isObsolete?: boolean | null; /** * The max version of the package in which the vulnerability exists. */ maxAffectedVersion?: Schema$Version; /** * The min version of the package in which the vulnerability exists. */ minAffectedVersion?: Schema$Version; /** * Required. The name of the package where the vulnerability was found. */ package?: string | null; /** * The type of package; whether native or non native(ruby gems, node.js packages etc). */ packageType?: string | null; /** * The severity (eg: distro assigned severity) for this vulnerability. */ severityName?: string | null; /** * The source from which the information in this Detail was obtained. */ source?: string | null; /** * The time this information was last changed at the source. This is an upstream timestamp from the underlying information source - e.g. Ubuntu security tracker. */ sourceUpdateTime?: string | null; } /** * Details of an attestation occurrence. */ export interface Schema$Details { /** * Required. Attestation for the resource. */ attestation?: Schema$Attestation; } /** * Provides information about the analysis status of a discovered resource. */ export interface Schema$Discovered { /** * The status of discovery for the resource. */ analysisStatus?: string | null; /** * When an error is encountered this will contain a LocalizedMessage under details to show to the user. The LocalizedMessage is output only and populated by the API. */ analysisStatusError?: Schema$Status; /** * Whether the resource is continuously analyzed. */ continuousAnalysis?: string | null; /** * The last time continuous analysis was done for this resource. Deprecated, do not use. */ lastAnalysisTime?: string | null; } /** * A note that indicates a type of analysis a provider would perform. This note exists in a provider's project. A `Discovery` occurrence is created in a consumer's project at the start of analysis. */ export interface Schema$Discovery { /** * Required. Immutable. The kind of analysis that is handled by this discovery. */ analysisKind?: string | null; } /** * This represents a particular channel of distribution for a given package. E.g., Debian's jessie-backports dpkg mirror. */ export interface Schema$Distribution { /** * The CPU architecture for which packages in this distribution channel were built. */ architecture?: string | null; /** * Required. The cpe_uri in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. */ cpeUri?: string | null; /** * The distribution channel-specific description of this package. */ description?: string | null; /** * The latest available version of this package in this distribution channel. */ latestVersion?: Schema$Version; /** * A freeform string denoting the maintainer of this package. */ maintainer?: string | null; /** * The distribution channel-specific homepage for this package. */ url?: string | null; } /** * 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 { } /** * Defines an object for the environment field in in-toto links. The suggested fields are "variables", "filesystem", and "workdir". */ export interface Schema$Environment { customValues?: { [key: string]: string; } | null; } /** * 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; } /** * Container message for hashes of byte content of files, used in source messages to verify integrity of source input to the build. */ export interface Schema$FileHashes { /** * Required. Collection of file hashes. */ fileHash?: Schema$Hash[]; } /** * A set of properties that uniquely identify a given Docker image. */ export interface Schema$Fingerprint { /** * Required. The layer ID of the final layer in the Docker image's v1 representation. */ v1Name?: string | null; /** * Required. The ordered list of v2 blobs that represent a given image. */ v2Blob?: string[] | null; /** * Output only. The name of the image's v2 blobs computed via: [bottom] := v2_blobbottom := sha256(v2_blob[N] + " " + v2_name[N+1]) Only the name of the final blob is kept. */ v2Name?: string | null; } /** * Per resource and severity counts of fixable and total vulnerabilities. */ export interface Schema$FixableTotalByDigest { /** * The number of fixable vulnerabilities associated with this resource. */ fixableCount?: string | null; /** * The affected resource. */ resource?: Schema$Resource; /** * The severity for this count. SEVERITY_UNSPECIFIED indicates total across all severities. */ severity?: string | null; /** * The total number of vulnerabilities associated with this resource. */ totalCount?: string | null; } /** * An attestation wrapper that uses the Grafeas `Signature` message. This attestation must define the `serialized_payload` that the `signatures` verify and any metadata necessary to interpret that plaintext. The signatures should always be over the `serialized_payload` bytestring. */ export interface Schema$GenericSignedAttestation { /** * Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). */ contentType?: string | null; /** * The serialized payload that is verified by one or more `signatures`. The encoding and semantic meaning of this payload must match what is set in `content_type`. */ serializedPayload?: string | null; /** * One or more signatures over `serialized_payload`. Verifier implementations should consider this attestation message verified if at least one `signature` verifies `serialized_payload`. See `Signature` in common.proto for more details on signature structure and verification. */ signatures?: Schema$Signature[]; } /** * A SourceContext referring to a Gerrit project. */ export interface Schema$GerritSourceContext { /** * An alias, which may be a branch or tag. */ aliasContext?: Schema$AliasContext; /** * The full project name within the host. Projects may be nested, so "project/subproject" is a valid project name. The "repo name" is the hostURI/project. */ gerritProject?: string | null; /** * The URI of a running Gerrit instance. */ hostUri?: string | null; /** * A revision (commit) ID. */ revisionId?: 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; } /** * A GitSourceContext denotes a particular revision in a third party Git repository (e.g., GitHub). */ export interface Schema$GitSourceContext { /** * Git commit hash. */ revisionId?: string | null; /** * Git repository URL. */ url?: string | null; } /** * Metadata for all operations used and required for all operations that created by Container Analysis Providers */ export interface Schema$GoogleDevtoolsContaineranalysisV1alpha1OperationMetadata { /** * Output only. The time this operation was created. */ createTime?: string | null; /** * Output only. The time that this operation was marked completed or failed. */ endTime?: string | null; } /** * Details of a build occurrence. */ export interface Schema$GrafeasV1beta1BuildDetails { /** * Required. The actual provenance for the build. */ provenance?: Schema$BuildProvenance; /** * Serialized JSON representation of the provenance, used in generating the build signature in the corresponding build note. After verifying the signature, `provenance_bytes` can be unmarshalled and compared to the provenance to confirm that it is unchanged. A base64-encoded string representation of the provenance bytes is used for the signature in order to interoperate with openssl which expects this format for signature verification. The serialized form is captured both to avoid ambiguity in how the provenance is marshalled to json as well to prevent incompatibilities with future changes. */ provenanceBytes?: string | null; } /** * Details of a deployment occurrence. */ export interface Schema$GrafeasV1beta1DeploymentDetails { /** * Required. Deployment history for the resource. */ deployment?: Schema$Deployment; } /** * Details of a discovery occurrence. */ export interface Schema$GrafeasV1beta1DiscoveryDetails { /** * Required. Analysis status for the discovered resource. */ discovered?: Schema$Discovered; } /** * Details of an image occurrence. */ export interface Schema$GrafeasV1beta1ImageDetails { /** * Required. Immutable. The child image derived from the base image. */ derivedImage?: Schema$Derived; } export interface Schema$GrafeasV1beta1IntotoArtifact { hashes?: Schema$ArtifactHashes; resourceUri?: string | null; } /** * This corresponds to a signed in-toto link - it is made up of one or more signatures and the in-toto link itself. This is used for occurrences of a Grafeas in-toto note. */ export interface Schema$GrafeasV1beta1IntotoDetails { signatures?: Schema$GrafeasV1beta1IntotoSignature[]; signed?: Schema$Link; } /** * A signature object consists of the KeyID used and the signature itself. */ export interface Schema$GrafeasV1beta1IntotoSignature { keyid?: string | null; sig?: string | null; } /** * Details of a package occurrence. */ export interface Schema$GrafeasV1beta1PackageDetails { /** * Required. Where the package was installed. */ installation?: Schema$Installation; } /** * Details of a vulnerability Occurrence. */ export interface Schema$GrafeasV1beta1VulnerabilityDetails { /** * Output only. The CVSS score of this vulnerability. CVSS score is on a scale of 0-10 where 0 indicates low severity and 10 indicates high severity. */ cvssScore?: number | null; /** * The distro assigned severity for this vulnerability when it is available, and note provider assigned severity when distro has not yet assigned a severity for this vulnerability. */ effectiveSeverity?: string | null; /** * Output only. A detailed description of this vulnerability. */ longDescription?: string | null; /** * Required. The set of affected locations and their fixes (if available) within the associated resource. */ packageIssue?: Schema$PackageIssue[]; /** * Output only. URLs related to this vulnerability. */ relatedUrls?: Schema$RelatedUrl[]; /** * Output only. The note provider assigned Severity of the vulnerability. */ severity?: string | null; /** * Output only. A one sentence description of this vulnerability. */ shortDescription?: string | null; /** * The type of package; whether native or non native(ruby gems, node.js packages etc) */ type?: string | null; } /** * Container message for hash values. */ export interface Schema$Hash { /** * Required. The type of hash that was performed. */ type?: string | null; /** * Required. The hash value. */ value?: string | null; } /** * This submessage provides human-readable hints about the purpose of the authority. Because the name of a note acts as its resource reference, it is important to disambiguate the canonical name of the Note (which might be a UUID for security purposes) from "readable" names more suitable for debug output. Note that these hints should not be used to look up authorities in security sensitive contexts, such as when looking up attestations to verify. */ export interface Schema$Hint { /** * Required. The human readable name of this attestation authority, for example "qa". */ humanReadableName?: string | null; } /** * This represents how a particular software package may be installed on a system. */ export interface Schema$Installation { /** * Required. All of the places within the filesystem versions of this package have been found. */ location?: Schema$Location[]; /** * Output only. The name of the installed package. */ name?: string | null; } /** * This contains the fields corresponding to the definition of a software supply chain step in an in-toto layout. This information goes into a Grafeas note. */ export interface Schema$InToto { /** * This field contains the expected command used to perform the step. */ expectedCommand?: string[] | null; /** * The following fields contain in-toto artifact rules identifying the artifacts that enter this supply chain step, and exit the supply chain step, i.e. materials and products of the step. */ expectedMaterials?: Schema$ArtifactRule[]; expectedProducts?: Schema$ArtifactRule[]; /** * This field contains the public keys that can be used to verify the signatures on the step metadata. */ signingKeys?: Schema$SigningKey[]; /** * This field identifies the name of the step in the supply chain. */ stepName?: string | null; /** * This field contains a value that indicates the minimum number of keys that need to be used to sign the step's in-toto link. */ threshold?: string | null; } export interface Schema$KnowledgeBase { /** * The KB name (generally of the form KB[0-9]+ i.e. KB123456). */ name?: string | null; /** * A link to the KB in the Windows update catalog - https://www.catalog.update.microsoft.com/ */ url?: string | null; } /** * Layer holds metadata specific to a layer of a Docker image. */ export interface Schema$Layer { /** * The recovered arguments to the Dockerfile directive. */ arguments?: string | null; /** * Required. The recovered Dockerfile directive used to construct this layer. */ directive?: string | null; } /** * This corresponds to an in-toto link. */ export interface Schema$Link { /** * ByProducts are data generated as part of a software supply chain step, but are not the actual result of the step. */ byproducts?: Schema$ByProducts; /** * This field contains the full command executed for the step. This can also be empty if links are generated for operations that aren't directly mapped to a specific command. Each term in the command is an independent string in the list. An example of a command in the in-toto metadata field is: "command": ["git", "clone", "https://github.com/in-toto/demo-project.git"] */ command?: string[] | null; /** * This is a field that can be used to capture information about the environment. It is suggested for this field to contain information that details environment variables, filesystem information, and the present working directory. The recommended structure of this field is: "environment": { "custom_values": { "variables": "", "filesystem": "", "workdir": "", "": "..." \} \} */ environment?: Schema$Environment; /** * Materials are the supply chain artifacts that go into the step and are used for the operation performed. The key of the map is the path of the artifact and the structure contains the recorded hash information. An example is: "materials": [ { "resource_uri": "foo/bar", "hashes": { "sha256": "ebebf...", : \} \} ] */ materials?: Schema$GrafeasV1beta1IntotoArtifact[]; /** * Products are the supply chain artifacts generated as a result of the step. The structure is identical to that of materials. */ products?: Schema$GrafeasV1beta1IntotoArtifact[]; } /** * Response for listing occurrences for a note. */ export interface Schema$ListNoteOccurrencesResponse { /** * Token to provide to skip to a particular spot in the list. */ nextPageToken?: string | null; /** * The occurrences attached to the specified note. */ occurrences?: Schema$Occurrence[]; } /** * Response for listing notes. */ export interface Schema$ListNotesResponse { /** * The next pagination token in the list response. It should be used as `page_token` for the following request. An empty value means no more results. */ nextPageToken?: string | null; /** * The notes requested. */ notes?: Schema$Note[]; } /** * Response for listing occurrences. */ export interface Schema$ListOccurrencesResponse { /** * The next pagination token in the list response. It should be used as `page_token` for the following request. An empty value means no more results. */ nextPageToken?: string | null; /** * The occurrences requested. */ occurrences?: Schema$Occurrence[]; } /** * Response for listing scan configurations. */ export interface Schema$ListScanConfigsResponse { /** * The next pagination token in the list response. It should be used as `page_token` for the following request. An empty value means no more results. */ nextPageToken?: string | null; /** * The scan configurations requested. */ scanConfigs?: Schema$ScanConfig[]; } /** * An occurrence of a particular package installation found within a system's filesystem. E.g., glibc was found in `/var/lib/dpkg/status`. */ export interface Schema$Location { /** * Required. The CPE URI in [CPE format](https://cpe.mitre.org/specification/) denoting the package manager version distributing a package. */ cpeUri?: string | null; /** * The path from which we gathered that this package/version is installed. */ path?: string | null; /** * The version installed at this location. */ version?: Schema$Version; } /** * A type of analysis that can be done for a resource. */ export interface Schema$Note { /** * A note describing an attestation role. */ attestationAuthority?: Schema$Authority; /** * A note describing a base image. */ baseImage?: Schema$Basis; /** * A note describing build provenance for a verifiable build. */ build?: Schema$Build; /** * Output only. The time this note was created. This field can be used as a filter in list requests. */ createTime?: string | null; /** * A note describing something that can be deployed. */ deployable?: Schema$Deployable; /** * A note describing the initial analysis of a resource. */ discovery?: Schema$Discovery; /** * Time of expiration for this note. Empty if note does not expire. */ expirationTime?: string | null; /** * A note describing an in-toto link. */ intoto?: Schema$InToto; /** * Output only. The type of analysis. This field can be used as a filter in list requests. */ kind?: string | null; /** * A detailed description of this note. */ longDescription?: string | null; /** * Output only. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. */ name?: string | null; /** * A note describing a package hosted by various package managers. */ package?: Schema$Package; /** * Other notes related to this note. */ relatedNoteNames?: string[] | null; /** * URLs associated with this note. */ relatedUrl?: Schema$RelatedUrl[]; /** * A one sentence description of this note. */ shortDescription?: string | null; /** * Output only. The time this note was last updated. This field can be used as a filter in list requests. */ updateTime?: string | null; /** * A note describing a package vulnerability. */ vulnerability?: Schema$Vulnerability; } /** * An instance of an analysis type that has been found on a resource. */ export interface Schema$Occurrence { /** * Describes an attestation of an artifact. */ attestation?: Schema$Details; /** * Describes a verifiable build. */ build?: Schema$GrafeasV1beta1BuildDetails; /** * Output only. The time this occurrence was created. */ createTime?: string | null; /** * Describes the deployment of an artifact on a runtime. */ deployment?: Schema$GrafeasV1beta1DeploymentDetails; /** * Describes how this resource derives from the basis in the associated note. */ derivedImage?: Schema$GrafeasV1beta1ImageDetails; /** * Describes when a resource was discovered. */ discovered?: Schema$GrafeasV1beta1DiscoveryDetails; /** * Describes the installation of a package on the linked resource. */ installation?: Schema$GrafeasV1beta1PackageDetails; /** * Describes a specific in-toto link. */ intoto?: Schema$GrafeasV1beta1IntotoDetails; /** * Output only. This explicitly denotes which of the occurrence details are specified. This field can be used as a filter in list requests. */ kind?: string | null; /** * Output only. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. */ name?: string | null; /** * Required. Immutable. The analysis note associated with this occurrence, in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. This field can be used as a filter in list requests. */ noteName?: string | null; /** * A description of actions that can be taken to remedy the note. */ remediation?: string | null; /** * Required. Immutable. The resource for which the occurrence applies. */ resource?: Schema$Resource; /** * Output only. The time this occurrence was last updated. */ updateTime?: string | null; /** * Describes a security vulnerability. */ vulnerability?: Schema$GrafeasV1beta1VulnerabilityDetails; } /** * This represents a particular package that is distributed over various channels. E.g., glibc (aka libc6) is distributed by many, at various versions. */ export interface Schema$Package { /** * The various channels by which a package is distributed. */ distribution?: Schema$Distribution[]; /** * Required. Immutable. The name of the package. */ name?: string | null; } /** * This message wraps a location affected by a vulnerability and its associated fix (if one is available). */ export interface Schema$PackageIssue { /** * Required. The location of the vulnerability. */ affectedLocation?: Schema$VulnerabilityLocation; /** * The location of the available fix for vulnerability. */ fixedLocation?: Schema$VulnerabilityLocation; /** * Deprecated, use Details.effective_severity instead The severity (e.g., distro assigned severity) for this vulnerability. */ severityName?: string | null; } /** * An attestation wrapper with a PGP-compatible signature. This message only supports `ATTACHED` signatures, where the payload that is signed is included alongside the signature itself in the same file. */ export interface Schema$PgpSignedAttestation { /** * Type (for example schema) of the attestation payload that was signed. The verifier must ensure that the provided type is one that the verifier supports, and that the attestation payload is a valid instantiation of that type (for example by validating a JSON schema). */ contentType?: string | null; /** * The cryptographic fingerprint of the key used to generate the signature, as output by, e.g. `gpg --list-keys`. This should be the version 4, full 160-bit fingerprint, expressed as a 40 character hexidecimal string. See https://tools.ietf.org/html/rfc4880#section-12.2 for details. Implementations may choose to acknowledge "LONG", "SHORT", or other abbreviated key IDs, but only the full fingerprint is guaranteed to work. In gpg, the full fingerprint can be retrieved from the `fpr` field returned when calling --list-keys with --with-colons. For example: ``` gpg -