models

package
v0.0.0-...-51a7260 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 1, 2024 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Overview

Package models provides primitives to interact with the openapi HTTP API.

Code generated by github.com/deepmap/oapi-codegen/v2 version v2.1.0 DO NOT EDIT.

Index

Constants

View Source
const DefaultMaxParallelScanners int = 2

Variables

This section is empty.

Functions

func CoalesceComparable

func CoalesceComparable[T comparable](original, target T) (T, error)

CoalesceComparable will return original if target is not set, and target if original is not set. If both are set then they must be the same otherwise an error is raised.

func MapToTags

func MapToTags(tags map[string]string) *[]Tag

func MergeTags

func MergeTags(left, right *[]Tag) *[]Tag

func UnionSlices

func UnionSlices[T comparable](inputs ...[]T) []T

UnionSlices returns the union of the input slices.

func ValueOrZero

func ValueOrZero[T any](ptr *T) T

ValueOrZero returns the value that the pointer ptr pointers to. It returns the zero value if ptr is nil.

Types

type Annotations

type Annotations = []struct {
	Key   *string `json:"key,omitempty"`
	Value *string `json:"value,omitempty"`
}

Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.

type ApiResponse

type ApiResponse struct {
	Message *string `json:"message,omitempty"`
}

ApiResponse An object that is returned in all cases of failures.

type Asset

type Asset struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`
	AssetInfo   *AssetType   `json:"assetInfo,omitempty"`
	FirstSeen   *time.Time   `json:"firstSeen,omitempty"`
	Id          *string      `json:"id,omitempty"`
	LastSeen    *time.Time   `json:"lastSeen,omitempty"`

	// Providers List of providers which discover the asset.
	Providers *[]ProviderRelationship `json:"providers,omitempty"`
	Revision  *int                    `json:"revision,omitempty"`

	// ScansCount Total number of scans that have ever run for this asset
	ScansCount *int `json:"scansCount,omitempty"`

	// Summary A summary of the scan findings.
	Summary      *ScanFindingsSummary `json:"summary,omitempty"`
	TerminatedOn *time.Time           `json:"terminatedOn,omitempty"`
}

Asset defines model for Asset.

type AssetCommon

type AssetCommon = map[string]interface{}

AssetCommon defines model for AssetCommon.

type AssetExists

type AssetExists struct {
	// Asset Describes an asset object.
	Asset *Asset `json:"asset,omitempty"`

	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`
}

AssetExists defines model for AssetExists.

type AssetID

type AssetID = string

AssetID defines model for assetID.

type AssetRelationship

type AssetRelationship struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`
	AssetInfo   *AssetType   `json:"assetInfo,omitempty"`
	FirstSeen   *time.Time   `json:"firstSeen,omitempty"`
	Id          string       `json:"id"`
	LastSeen    *time.Time   `json:"lastSeen,omitempty"`

	// Providers List of providers which discover the asset.
	Providers *[]ProviderRelationship `json:"providers,omitempty"`
	Revision  *int                    `json:"revision,omitempty"`

	// ScansCount Total number of scans that have ever run for this asset
	ScansCount *int `json:"scansCount,omitempty"`

	// Summary A summary of the scan findings.
	Summary      *ScanFindingsSummary `json:"summary,omitempty"`
	TerminatedOn *time.Time           `json:"terminatedOn,omitempty"`
}

AssetRelationship defines model for AssetRelationship.

func (*AssetRelationship) ToAsset

func (a *AssetRelationship) ToAsset() (*Asset, error)

type AssetScan

type AssetScan struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// Asset Describes a relationship to an asset which can be expanded.
	Asset             *AssetRelationship    `json:"asset,omitempty"`
	Exploits          *ExploitScan          `json:"exploits,omitempty"`
	FindingsProcessed *bool                 `json:"findingsProcessed,omitempty"`
	Id                *string               `json:"id,omitempty"`
	InfoFinder        *InfoFinderScan       `json:"infoFinder,omitempty"`
	Malware           *MalwareScan          `json:"malware,omitempty"`
	Misconfigurations *MisconfigurationScan `json:"misconfigurations,omitempty"`

	// Provider Describes a relationship to a provider which can be expanded.
	Provider              *ProviderRelationship  `json:"provider,omitempty"`
	ResourceCleanupStatus *ResourceCleanupStatus `json:"resourceCleanupStatus,omitempty"`
	Revision              *int                   `json:"revision,omitempty"`
	Rootkits              *RootkitScan           `json:"rootkits,omitempty"`
	Sbom                  *SbomScan              `json:"sbom,omitempty"`

	// Scan Describes an expandable relationship to Scan object
	Scan *ScanRelationship `json:"scan,omitempty"`

	// ScanFamiliesConfig The configuration of the scanner families within a scan config
	ScanFamiliesConfig *ScanFamiliesConfig `json:"scanFamiliesConfig,omitempty"`

	// ScannerInstanceCreationConfig Configuration of scanner instance
	ScannerInstanceCreationConfig *ScannerInstanceCreationConfig `json:"scannerInstanceCreationConfig,omitempty"`
	Secrets                       *SecretScan                    `json:"secrets,omitempty"`
	Stats                         *AssetScanStats                `json:"stats,omitempty"`
	Status                        *AssetScanStatus               `json:"status,omitempty"`

	// Summary A summary of the scan findings.
	Summary         *ScanFindingsSummary `json:"summary,omitempty"`
	Vulnerabilities *VulnerabilityScan   `json:"vulnerabilities,omitempty"`
}

AssetScan defines model for AssetScan.

func (*AssetScan) GetAssetID

func (r *AssetScan) GetAssetID() (string, bool)

func (*AssetScan) GetID

func (r *AssetScan) GetID() (string, bool)

func (*AssetScan) GetResourceCleanupStatus

func (r *AssetScan) GetResourceCleanupStatus() (ResourceCleanupStatus, bool)

func (*AssetScan) GetScanID

func (r *AssetScan) GetScanID() (string, bool)

func (*AssetScan) GetStatus

func (r *AssetScan) GetStatus() (AssetScanStatus, bool)

type AssetScanEstimation

type AssetScanEstimation struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// Asset Describes a relationship to an asset which can be expanded.
	Asset             *AssetRelationship `json:"asset,omitempty"`
	AssetScanTemplate *AssetScanTemplate `json:"assetScanTemplate,omitempty"`

	// DeleteAfter The time this resource should be deleted. This value is calculated by endTime + ttlSecondsAfterFinished. This should not be set by the user, but use ttlSecondsAfterFinished instead.
	DeleteAfter    *time.Time                  `json:"deleteAfter,omitempty"`
	EndTime        *time.Time                  `json:"endTime,omitempty"`
	Estimation     *Estimation                 `json:"estimation,omitempty"`
	Id             *string                     `json:"id,omitempty"`
	Revision       *int                        `json:"revision,omitempty"`
	ScanEstimation *ScanEstimationRelationship `json:"scanEstimation,omitempty"`
	StartTime      *time.Time                  `json:"startTime,omitempty"`
	Status         *AssetScanEstimationStatus  `json:"status,omitempty"`

	// TtlSecondsAfterFinished The duration in seconds this resource should last until it is deleted.
	TTLSecondsAfterFinished *int `json:"ttlSecondsAfterFinished,omitempty"`
}

AssetScanEstimation defines model for AssetScanEstimation.

func (*AssetScanEstimation) GetAssetID

func (r *AssetScanEstimation) GetAssetID() (string, bool)

func (*AssetScanEstimation) GetID

func (r *AssetScanEstimation) GetID() (string, bool)

func (*AssetScanEstimation) GetScanEstimationID

func (r *AssetScanEstimation) GetScanEstimationID() (string, bool)

func (*AssetScanEstimation) GetStatus

type AssetScanEstimationExists

type AssetScanEstimationExists struct {
	AssetScanEstimation *AssetScanEstimation `json:"assetScanEstimation,omitempty"`

	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`
}

AssetScanEstimationExists defines model for AssetScanEstimationExists.

type AssetScanEstimationID

type AssetScanEstimationID = string

AssetScanEstimationID defines model for assetScanEstimationID.

type AssetScanEstimationRelationship

type AssetScanEstimationRelationship struct {
	Id *string `json:"id,omitempty"`
}

AssetScanEstimationRelationship defines model for AssetScanEstimationRelationship.

type AssetScanEstimationStatus

type AssetScanEstimationStatus struct {
	// LastTransitionTime Last date time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human readable message.
	Message *string `json:"message,omitempty"`

	// Reason Machine readable reason for state transition.
	//
	// | State   | Reason       | Description                                                      |
	// | ------- | ------------ | ---------------------------------------------------------------- |
	// | Pending | Created      | AssetScanEstimation is pending as it has been newly created      |
	// | Aborted | Cancellation | AssetScanEstimation has been aborted due to cancellation request |
	// | Failed  | Aborted      | AssetScanEstimation has failed due to abort                      |
	// | Failed  | Error        | AssetScanEstimation has failed due to an error                   |
	// | Done    | Success      | AssetScanEstimation has finished successfully                    |
	Reason AssetScanEstimationStatusReason `json:"reason"`

	// State Describes the state of asset scan estimation.
	//
	// | State   | Description                                   |
	// | ------- | --------------------------------------------- |
	// | Pending | Initial state for AssetScanEstimation         |
	// | Aborted | AssetScanEstimation has been aborted          |
	// | Failed  | AssetScanEstimation has been failed           |
	// | Done    | AssetScanEstimation has finished successfully |
	State AssetScanEstimationStatusState `json:"state"`
}

AssetScanEstimationStatus defines model for AssetScanEstimationStatus.

func (*AssetScanEstimationStatus) Equals

func (*AssetScanEstimationStatus) IsValidTransition

type AssetScanEstimationStatusReason

type AssetScanEstimationStatusReason string

AssetScanEstimationStatusReason Machine readable reason for state transition.

| State | Reason | Description | | ------- | ------------ | ---------------------------------------------------------------- | | Pending | Created | AssetScanEstimation is pending as it has been newly created | | Aborted | Cancellation | AssetScanEstimation has been aborted due to cancellation request | | Failed | Aborted | AssetScanEstimation has failed due to abort | | Failed | Error | AssetScanEstimation has failed due to an error | | Done | Success | AssetScanEstimation has finished successfully |

const (
	AssetScanEstimationStatusReasonAborted      AssetScanEstimationStatusReason = "Aborted"
	AssetScanEstimationStatusReasonCancellation AssetScanEstimationStatusReason = "Cancellation"
	AssetScanEstimationStatusReasonCreated      AssetScanEstimationStatusReason = "Created"
	AssetScanEstimationStatusReasonError        AssetScanEstimationStatusReason = "Error"
	AssetScanEstimationStatusReasonSuccess      AssetScanEstimationStatusReason = "Success"
)

Defines values for AssetScanEstimationStatusReason.

type AssetScanEstimationStatusState

type AssetScanEstimationStatusState string

AssetScanEstimationStatusState Describes the state of asset scan estimation.

| State | Description | | ------- | --------------------------------------------- | | Pending | Initial state for AssetScanEstimation | | Aborted | AssetScanEstimation has been aborted | | Failed | AssetScanEstimation has been failed | | Done | AssetScanEstimation has finished successfully |

const (
	AssetScanEstimationStatusStateAborted AssetScanEstimationStatusState = "Aborted"
	AssetScanEstimationStatusStateDone    AssetScanEstimationStatusState = "Done"
	AssetScanEstimationStatusStateFailed  AssetScanEstimationStatusState = "Failed"
	AssetScanEstimationStatusStatePending AssetScanEstimationStatusState = "Pending"
)

Defines values for AssetScanEstimationStatusState.

type AssetScanEstimations

type AssetScanEstimations struct {
	// Count Total AssetScanEstimations count according to the given filters
	Count *int `json:"count,omitempty"`

	// Items List of AssetScanEstimations according to the given filters
	Items *[]AssetScanEstimation `json:"items,omitempty"`
}

AssetScanEstimations defines model for AssetScanEstimations.

type AssetScanExists

type AssetScanExists struct {
	AssetScan *AssetScan `json:"assetScan,omitempty"`

	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`
}

AssetScanExists defines model for AssetScanExists.

type AssetScanGeneralStats

type AssetScanGeneralStats struct {
	ScanTime *AssetScanScanTime `json:"scanTime,omitempty"`
}

AssetScanGeneralStats Global statistics for asset scan of all families.

type AssetScanID

type AssetScanID = string

AssetScanID defines model for assetScanID.

type AssetScanInputScanStats

type AssetScanInputScanStats struct {
	// Path The input path (/mnt/snapshot for ex.)
	Path     *string            `json:"path,omitempty"`
	ScanTime *AssetScanScanTime `json:"scanTime,omitempty"`

	// Size The input size in MB.
	Size *int64 `json:"size,omitempty"`

	// Type The input type (ROOTFS, DIR, IMAGE etc.)
	Type *string `json:"type,omitempty"`
}

AssetScanInputScanStats Statistics per asset scan input.

type AssetScanRelationship

type AssetScanRelationship struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// Asset Describes a relationship to an asset which can be expanded.
	Asset                 *AssetRelationship     `json:"asset,omitempty"`
	Exploits              *ExploitScan           `json:"exploits,omitempty"`
	FindingsProcessed     *bool                  `json:"findingsProcessed,omitempty"`
	Id                    string                 `json:"id"`
	InfoFinder            *InfoFinderScan        `json:"infoFinder,omitempty"`
	Malware               *MalwareScan           `json:"malware,omitempty"`
	Misconfigurations     *MisconfigurationScan  `json:"misconfigurations,omitempty"`
	ResourceCleanupStatus *ResourceCleanupStatus `json:"resourceCleanupStatus,omitempty"`
	Revision              *int                   `json:"revision,omitempty"`
	Rootkits              *RootkitScan           `json:"rootkits,omitempty"`
	Sbom                  *SbomScan              `json:"sbom,omitempty"`

	// Scan Describes an expandable relationship to Scan object
	Scan *ScanRelationship `json:"scan,omitempty"`

	// ScanFamiliesConfig The configuration of the scanner families within a scan config
	ScanFamiliesConfig *ScanFamiliesConfig `json:"scanFamiliesConfig,omitempty"`

	// ScannerInstanceCreationConfig Configuration of scanner instance
	ScannerInstanceCreationConfig *ScannerInstanceCreationConfig `json:"scannerInstanceCreationConfig,omitempty"`
	Secrets                       *SecretScan                    `json:"secrets,omitempty"`
	Stats                         *AssetScanStats                `json:"stats,omitempty"`
	Status                        *AssetScanStatus               `json:"status,omitempty"`

	// Summary A summary of the scan findings.
	Summary         *ScanFindingsSummary `json:"summary,omitempty"`
	Vulnerabilities *VulnerabilityScan   `json:"vulnerabilities,omitempty"`
}

AssetScanRelationship defines model for AssetScanRelationship.

type AssetScanScanTime

type AssetScanScanTime struct {
	EndTime   *time.Time `json:"endTime,omitempty"`
	StartTime *time.Time `json:"startTime,omitempty"`
}

AssetScanScanTime defines model for AssetScanScanTime.

type AssetScanStats

type AssetScanStats struct {
	Exploits *[]AssetScanInputScanStats `json:"exploits,omitempty"`

	// General Global statistics for asset scan of all families.
	General           *AssetScanGeneralStats     `json:"general,omitempty"`
	InfoFinder        *[]AssetScanInputScanStats `json:"infoFinder,omitempty"`
	Malware           *[]AssetScanInputScanStats `json:"malware,omitempty"`
	Misconfigurations *[]AssetScanInputScanStats `json:"misconfigurations,omitempty"`
	Rootkits          *[]AssetScanInputScanStats `json:"rootkits,omitempty"`
	Sbom              *[]AssetScanInputScanStats `json:"sbom,omitempty"`
	Secrets           *[]AssetScanInputScanStats `json:"secrets,omitempty"`
	Vulnerabilities   *[]AssetScanInputScanStats `json:"vulnerabilities,omitempty"`
}

AssetScanStats defines model for AssetScanStats.

type AssetScanStatus

type AssetScanStatus struct {
	// LastTransitionTime Last date time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human readable message.
	Message *string `json:"message,omitempty"`

	// Reason Machine readable reason for state transition.
	//
	// | State       | Reason           | Description                                                                                |
	// | ----------- | ---------------- | ------------------------------------------------------------------------------------------ |
	// | Pending     | Created          | Scan is pending as it has been newly created                                               |
	// | Scheduled   | Provisioning     | Scan is scheduled as Asset resources are being provisioned                                 |
	// | ReadyToScan | UnSupervised     | Scan is created manually without the involvement of the Orchestrator (e.g. CI/CD scenario) |
	// | ReadyToScan | ResourcesReady   | Scan is ready to scan as Asset resources have been provisioned                             |
	// | InProgress  | ScannerIsRunning | Scan is in progress as Scanner is still performing scanning on Asset resources             |
	// | Aborted     | Cancellation     | Scan has been aborted due to cancellation request                                          |
	// | Aborted     | Timeout          | Scan has been aborted due to timeout                                                       |
	// | Failed      | Error            | Scan has failed to one or more errors reported by the Scanner                              |
	// | Failed      | AbortTimeout     | Scan has failed due to being in Aborted state for too long                                 |
	// | Done        | Success          | Scan has finished successfully                                                             |
	Reason AssetScanStatusReason `json:"reason"`

	// State Describes the state of scan result.
	//
	// | State       | Description                                                                                      |
	// | ----------- | ------------------------------------------------------------------------------------------------ |
	// | Pending     | Initial state for AssetScan waiting for being scheduled                                          |
	// | Scheduled   | AssetScan which has been scheduled on Provider                                                   |
	// | ReadyToScan | Provider acknowledged that scanners for AssetScan is ready to run                                |
	// | InProgress  | Scanners are running on the Target                                                               |
	// | Aborted     | AssetScan has been aborted and all running Scanners need to be cancelled and shutdown gracefully |
	// | Failed      | Running Scanners on Target has failed, check *reason* and *message* fields for the details       |
	// | Done        | Running Scanners on Target has finished with no errors                                           |
	State AssetScanStatusState `json:"state"`
}

AssetScanStatus defines model for AssetScanStatus.

func (*AssetScanStatus) Equals

func (a *AssetScanStatus) Equals(b AssetScanStatus) bool

func (*AssetScanStatus) IsValidTransition

func (a *AssetScanStatus) IsValidTransition(b AssetScanStatus) error

type AssetScanStatusReason

type AssetScanStatusReason string

AssetScanStatusReason Machine readable reason for state transition.

| State | Reason | Description | | ----------- | ---------------- | ------------------------------------------------------------------------------------------ | | Pending | Created | Scan is pending as it has been newly created | | Scheduled | Provisioning | Scan is scheduled as Asset resources are being provisioned | | ReadyToScan | UnSupervised | Scan is created manually without the involvement of the Orchestrator (e.g. CI/CD scenario) | | ReadyToScan | ResourcesReady | Scan is ready to scan as Asset resources have been provisioned | | InProgress | ScannerIsRunning | Scan is in progress as Scanner is still performing scanning on Asset resources | | Aborted | Cancellation | Scan has been aborted due to cancellation request | | Aborted | Timeout | Scan has been aborted due to timeout | | Failed | Error | Scan has failed to one or more errors reported by the Scanner | | Failed | AbortTimeout | Scan has failed due to being in Aborted state for too long | | Done | Success | Scan has finished successfully |

const (
	AssetScanStatusReasonAbortTimeout     AssetScanStatusReason = "AbortTimedOut"
	AssetScanStatusReasonCancellation     AssetScanStatusReason = "Cancellation"
	AssetScanStatusReasonCreated          AssetScanStatusReason = "Created"
	AssetScanStatusReasonError            AssetScanStatusReason = "Error"
	AssetScanStatusReasonProvisioning     AssetScanStatusReason = "Provisioning"
	AssetScanStatusReasonResourcesReady   AssetScanStatusReason = "ResourcesReady"
	AssetScanStatusReasonScannerIsRunning AssetScanStatusReason = "ScannerIsRunning"
	AssetScanStatusReasonSuccess          AssetScanStatusReason = "Success"
	AssetScanStatusReasonTimeout          AssetScanStatusReason = "Timeout"
	AssetScanStatusReasonUnSupervised     AssetScanStatusReason = "UnSupervised"
)

Defines values for AssetScanStatusReason.

type AssetScanStatusState

type AssetScanStatusState string

AssetScanStatusState Describes the state of scan result.

| State | Description | | ----------- | ------------------------------------------------------------------------------------------------ | | Pending | Initial state for AssetScan waiting for being scheduled | | Scheduled | AssetScan which has been scheduled on Provider | | ReadyToScan | Provider acknowledged that scanners for AssetScan is ready to run | | InProgress | Scanners are running on the Target | | Aborted | AssetScan has been aborted and all running Scanners need to be cancelled and shutdown gracefully | | Failed | Running Scanners on Target has failed, check *reason* and *message* fields for the details | | Done | Running Scanners on Target has finished with no errors |

const (
	AssetScanStatusStateAborted     AssetScanStatusState = "Aborted"
	AssetScanStatusStateDone        AssetScanStatusState = "Done"
	AssetScanStatusStateFailed      AssetScanStatusState = "Failed"
	AssetScanStatusStateInProgress  AssetScanStatusState = "InProgress"
	AssetScanStatusStatePending     AssetScanStatusState = "Pending"
	AssetScanStatusStateReadyToScan AssetScanStatusState = "ReadyToScan"
	AssetScanStatusStateScheduled   AssetScanStatusState = "Scheduled"
)

Defines values for AssetScanStatusState.

type AssetScanTemplate

type AssetScanTemplate struct {
	// ScanFamiliesConfig The configuration of the scanner families within a scan config
	ScanFamiliesConfig *ScanFamiliesConfig `json:"scanFamiliesConfig,omitempty"`

	// ScannerInstanceCreationConfig Configuration of scanner instance
	ScannerInstanceCreationConfig *ScannerInstanceCreationConfig `json:"scannerInstanceCreationConfig,omitempty"`
}

AssetScanTemplate defines model for AssetScanTemplate.

func (*AssetScanTemplate) UseSpotInstances

func (a *AssetScanTemplate) UseSpotInstances() bool

type AssetScanTemplateReadOnly

type AssetScanTemplateReadOnly struct {
	// ScanFamiliesConfig The configuration of the scanner families within a scan config
	ScanFamiliesConfig *ScanFamiliesConfig `json:"scanFamiliesConfig,omitempty"`

	// ScannerInstanceCreationConfig Configuration of scanner instance
	ScannerInstanceCreationConfig *ScannerInstanceCreationConfig `json:"scannerInstanceCreationConfig,omitempty"`
}

AssetScanTemplateReadOnly defines model for AssetScanTemplateReadOnly.

type AssetScans

type AssetScans struct {
	// Count Total asset scans count according to the given filters
	Count *int `json:"count,omitempty"`

	// Items List of asset scans according to the given filters and page. List length must be lower or equal to pageSize.
	Items *[]AssetScan `json:"items,omitempty"`
}

AssetScans defines model for AssetScans.

type AssetType

type AssetType struct {
	// contains filtered or unexported fields
}

AssetType defines model for AssetType.

func (AssetType) AsContainerImageInfo

func (t AssetType) AsContainerImageInfo() (ContainerImageInfo, error)

AsContainerImageInfo returns the union data inside the AssetType as a ContainerImageInfo

func (AssetType) AsContainerInfo

func (t AssetType) AsContainerInfo() (ContainerInfo, error)

AsContainerInfo returns the union data inside the AssetType as a ContainerInfo

func (AssetType) AsDirInfo

func (t AssetType) AsDirInfo() (DirInfo, error)

AsDirInfo returns the union data inside the AssetType as a DirInfo

func (AssetType) AsPodInfo

func (t AssetType) AsPodInfo() (PodInfo, error)

AsPodInfo returns the union data inside the AssetType as a PodInfo

func (AssetType) AsVMInfo

func (t AssetType) AsVMInfo() (VMInfo, error)

AsVMInfo returns the union data inside the AssetType as a VMInfo

func (AssetType) Discriminator

func (t AssetType) Discriminator() (string, error)

func (*AssetType) FromContainerImageInfo

func (t *AssetType) FromContainerImageInfo(v ContainerImageInfo) error

FromContainerImageInfo overwrites any union data inside the AssetType as the provided ContainerImageInfo

func (*AssetType) FromContainerInfo

func (t *AssetType) FromContainerInfo(v ContainerInfo) error

FromContainerInfo overwrites any union data inside the AssetType as the provided ContainerInfo

func (*AssetType) FromDirInfo

func (t *AssetType) FromDirInfo(v DirInfo) error

FromDirInfo overwrites any union data inside the AssetType as the provided DirInfo

func (*AssetType) FromPodInfo

func (t *AssetType) FromPodInfo(v PodInfo) error

FromPodInfo overwrites any union data inside the AssetType as the provided PodInfo

func (*AssetType) FromVMInfo

func (t *AssetType) FromVMInfo(v VMInfo) error

FromVMInfo overwrites any union data inside the AssetType as the provided VMInfo

func (AssetType) MarshalJSON

func (t AssetType) MarshalJSON() ([]byte, error)

func (*AssetType) MergeContainerImageInfo

func (t *AssetType) MergeContainerImageInfo(v ContainerImageInfo) error

MergeContainerImageInfo performs a merge with any union data inside the AssetType, using the provided ContainerImageInfo

func (*AssetType) MergeContainerInfo

func (t *AssetType) MergeContainerInfo(v ContainerInfo) error

MergeContainerInfo performs a merge with any union data inside the AssetType, using the provided ContainerInfo

func (*AssetType) MergeDirInfo

func (t *AssetType) MergeDirInfo(v DirInfo) error

MergeDirInfo performs a merge with any union data inside the AssetType, using the provided DirInfo

func (*AssetType) MergePodInfo

func (t *AssetType) MergePodInfo(v PodInfo) error

MergePodInfo performs a merge with any union data inside the AssetType, using the provided PodInfo

func (*AssetType) MergeVMInfo

func (t *AssetType) MergeVMInfo(v VMInfo) error

MergeVMInfo performs a merge with any union data inside the AssetType, using the provided VMInfo

func (*AssetType) UnmarshalJSON

func (t *AssetType) UnmarshalJSON(b []byte) error

func (AssetType) ValueByDiscriminator

func (t AssetType) ValueByDiscriminator() (interface{}, error)

type Assets

type Assets struct {
	// Count Total assets count according the given filters
	Count *int `json:"count,omitempty"`

	// Items List of assets in the given filters and page. List length must be lower or equal to pageSize.
	Items *[]Asset `json:"items,omitempty"`
}

Assets defines model for Assets.

type CloudProvider

type CloudProvider string

CloudProvider defines model for CloudProvider.

const (
	AWS        CloudProvider = "AWS"
	Azure      CloudProvider = "Azure"
	Docker     CloudProvider = "Docker"
	External   CloudProvider = "External"
	GCP        CloudProvider = "GCP"
	Kubernetes CloudProvider = "Kubernetes"
)

Defines values for CloudProvider.

func (*CloudProvider) UnmarshalText

func (p *CloudProvider) UnmarshalText(text []byte) error

type ContainerImageInfo

type ContainerImageInfo struct {
	Architecture *string   `json:"architecture,omitempty"`
	ImageID      string    `json:"imageID"`
	Labels       *[]Tag    `json:"labels"`
	ObjectType   string    `json:"objectType"`
	Os           *string   `json:"os,omitempty"`
	RepoDigests  *[]string `json:"repoDigests,omitempty"`
	RepoTags     *[]string `json:"repoTags,omitempty"`
	Size         *int64    `json:"size,omitempty"`
}

ContainerImageInfo defines model for ContainerImageInfo.

func (*ContainerImageInfo) GetFirstRepoDigest

func (c *ContainerImageInfo) GetFirstRepoDigest() (string, bool)

GetFirstRepoDigest returns the first repo digest if it exists. Otherwise, returns false.

func (*ContainerImageInfo) GetFirstRepoTag

func (c *ContainerImageInfo) GetFirstRepoTag() (string, bool)

GetFirstRepoTag returns the first repo tag if it exists. Otherwise, returns false.

func (ContainerImageInfo) Merge

Merge merges target and c together and then returns the merged result. c is not a pointer so that: a) a non-pointer ContainerImageInfo can be merged. b) the source ContainerimageInfo can not be modified by this function.

func (ContainerImageInfo) String

func (c ContainerImageInfo) String() string

type ContainerInfo

type ContainerInfo struct {
	ContainerID   string              `json:"containerID"`
	ContainerName *string             `json:"containerName,omitempty"`
	CreatedAt     *time.Time          `json:"createdAt,omitempty"`
	Image         *ContainerImageInfo `json:"image,omitempty"`
	Labels        *[]Tag              `json:"labels"`
	Location      *string             `json:"location,omitempty"`
	ObjectType    string              `json:"objectType"`
}

ContainerInfo defines model for ContainerInfo.

type CostBreakdownComponent

type CostBreakdownComponent struct {
	Cost      float32 `json:"cost"`
	Operation string  `json:"operation"`
}

CostBreakdownComponent defines model for CostBreakdownComponent.

type DirInfo

type DirInfo struct {
	DirName    *string `json:"dirName,omitempty"`
	Location   *string `json:"location,omitempty"`
	ObjectType string  `json:"objectType"`
}

DirInfo defines model for DirInfo.

type Estimation

type Estimation struct {
	// Cost The estimated scan cost ($)
	Cost          *float32                  `json:"cost,omitempty"`
	CostBreakdown *[]CostBreakdownComponent `json:"costBreakdown,omitempty"`

	// Duration The estimated scan duration (seconds)
	Duration *int `json:"duration,omitempty"`

	// Size The estimated scan size (GB)
	Size *int `json:"size,omitempty"`
}

Estimation defines model for Estimation.

type Exploit

type Exploit struct {
	CveID       *string   `json:"cveID,omitempty"`
	Description *string   `json:"description,omitempty"`
	Name        *string   `json:"name,omitempty"`
	SourceDB    *string   `json:"sourceDB,omitempty"`
	Title       *string   `json:"title,omitempty"`
	Urls        *[]string `json:"urls"`
}

Exploit defines model for Exploit.

type ExploitFindingInfo

type ExploitFindingInfo struct {
	CveID       *string   `json:"cveID,omitempty"`
	Description *string   `json:"description,omitempty"`
	Name        *string   `json:"name,omitempty"`
	ObjectType  string    `json:"objectType"`
	SourceDB    *string   `json:"sourceDB,omitempty"`
	Title       *string   `json:"title,omitempty"`
	Urls        *[]string `json:"urls"`
}

ExploitFindingInfo defines model for ExploitFindingInfo.

type ExploitScan

type ExploitScan struct {
	Exploits *[]Exploit     `json:"exploits"`
	Status   *ScannerStatus `json:"status,omitempty"`
}

ExploitScan defines model for ExploitScan.

type ExploitsConfig

type ExploitsConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

ExploitsConfig defines model for ExploitsConfig.

func (*ExploitsConfig) GetScannersList

func (c *ExploitsConfig) GetScannersList() []string

func (*ExploitsConfig) IsEnabled

func (c *ExploitsConfig) IsEnabled() bool

type FamilyConfigEnabler

type FamilyConfigEnabler interface {
	IsEnabled() bool
}

type Finding

type Finding struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// Asset Describes a relationship to an asset which can be expanded.
	Asset       *AssetRelationship     `json:"asset,omitempty"`
	FindingInfo *Finding_FindingInfo   `json:"findingInfo,omitempty"`
	FoundBy     *AssetScanRelationship `json:"foundBy,omitempty"`

	// FoundOn When this finding was discovered by a scan
	FoundOn *time.Time `json:"foundOn,omitempty"`
	Id      *string    `json:"id,omitempty"`

	// InvalidatedOn When this finding was invalidated by a newer scan
	InvalidatedOn *time.Time `json:"invalidatedOn,omitempty"`
}

Finding defines model for Finding.

type FindingExists

type FindingExists struct {
	Finding *Finding `json:"finding,omitempty"`

	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`
}

FindingExists defines model for FindingExists.

type FindingID

type FindingID = string

FindingID defines model for findingID.

type Finding_FindingInfo

type Finding_FindingInfo struct {
	// contains filtered or unexported fields
}

Finding_FindingInfo defines model for Finding.FindingInfo.

func (Finding_FindingInfo) AsExploitFindingInfo

func (t Finding_FindingInfo) AsExploitFindingInfo() (ExploitFindingInfo, error)

AsExploitFindingInfo returns the union data inside the Finding_FindingInfo as a ExploitFindingInfo

func (Finding_FindingInfo) AsInfoFinderFindingInfo

func (t Finding_FindingInfo) AsInfoFinderFindingInfo() (InfoFinderFindingInfo, error)

AsInfoFinderFindingInfo returns the union data inside the Finding_FindingInfo as a InfoFinderFindingInfo

func (Finding_FindingInfo) AsMalwareFindingInfo

func (t Finding_FindingInfo) AsMalwareFindingInfo() (MalwareFindingInfo, error)

AsMalwareFindingInfo returns the union data inside the Finding_FindingInfo as a MalwareFindingInfo

func (Finding_FindingInfo) AsMisconfigurationFindingInfo

func (t Finding_FindingInfo) AsMisconfigurationFindingInfo() (MisconfigurationFindingInfo, error)

AsMisconfigurationFindingInfo returns the union data inside the Finding_FindingInfo as a MisconfigurationFindingInfo

func (Finding_FindingInfo) AsPackageFindingInfo

func (t Finding_FindingInfo) AsPackageFindingInfo() (PackageFindingInfo, error)

AsPackageFindingInfo returns the union data inside the Finding_FindingInfo as a PackageFindingInfo

func (Finding_FindingInfo) AsRootkitFindingInfo

func (t Finding_FindingInfo) AsRootkitFindingInfo() (RootkitFindingInfo, error)

AsRootkitFindingInfo returns the union data inside the Finding_FindingInfo as a RootkitFindingInfo

func (Finding_FindingInfo) AsSecretFindingInfo

func (t Finding_FindingInfo) AsSecretFindingInfo() (SecretFindingInfo, error)

AsSecretFindingInfo returns the union data inside the Finding_FindingInfo as a SecretFindingInfo

func (Finding_FindingInfo) AsVulnerabilityFindingInfo

func (t Finding_FindingInfo) AsVulnerabilityFindingInfo() (VulnerabilityFindingInfo, error)

AsVulnerabilityFindingInfo returns the union data inside the Finding_FindingInfo as a VulnerabilityFindingInfo

func (Finding_FindingInfo) Discriminator

func (t Finding_FindingInfo) Discriminator() (string, error)

func (*Finding_FindingInfo) FromExploitFindingInfo

func (t *Finding_FindingInfo) FromExploitFindingInfo(v ExploitFindingInfo) error

FromExploitFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided ExploitFindingInfo

func (*Finding_FindingInfo) FromInfoFinderFindingInfo

func (t *Finding_FindingInfo) FromInfoFinderFindingInfo(v InfoFinderFindingInfo) error

FromInfoFinderFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided InfoFinderFindingInfo

func (*Finding_FindingInfo) FromMalwareFindingInfo

func (t *Finding_FindingInfo) FromMalwareFindingInfo(v MalwareFindingInfo) error

FromMalwareFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided MalwareFindingInfo

func (*Finding_FindingInfo) FromMisconfigurationFindingInfo

func (t *Finding_FindingInfo) FromMisconfigurationFindingInfo(v MisconfigurationFindingInfo) error

FromMisconfigurationFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided MisconfigurationFindingInfo

func (*Finding_FindingInfo) FromPackageFindingInfo

func (t *Finding_FindingInfo) FromPackageFindingInfo(v PackageFindingInfo) error

FromPackageFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided PackageFindingInfo

func (*Finding_FindingInfo) FromRootkitFindingInfo

func (t *Finding_FindingInfo) FromRootkitFindingInfo(v RootkitFindingInfo) error

FromRootkitFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided RootkitFindingInfo

func (*Finding_FindingInfo) FromSecretFindingInfo

func (t *Finding_FindingInfo) FromSecretFindingInfo(v SecretFindingInfo) error

FromSecretFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided SecretFindingInfo

func (*Finding_FindingInfo) FromVulnerabilityFindingInfo

func (t *Finding_FindingInfo) FromVulnerabilityFindingInfo(v VulnerabilityFindingInfo) error

FromVulnerabilityFindingInfo overwrites any union data inside the Finding_FindingInfo as the provided VulnerabilityFindingInfo

func (Finding_FindingInfo) MarshalJSON

func (t Finding_FindingInfo) MarshalJSON() ([]byte, error)

func (*Finding_FindingInfo) MergeExploitFindingInfo

func (t *Finding_FindingInfo) MergeExploitFindingInfo(v ExploitFindingInfo) error

MergeExploitFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided ExploitFindingInfo

func (*Finding_FindingInfo) MergeInfoFinderFindingInfo

func (t *Finding_FindingInfo) MergeInfoFinderFindingInfo(v InfoFinderFindingInfo) error

MergeInfoFinderFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided InfoFinderFindingInfo

func (*Finding_FindingInfo) MergeMalwareFindingInfo

func (t *Finding_FindingInfo) MergeMalwareFindingInfo(v MalwareFindingInfo) error

MergeMalwareFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided MalwareFindingInfo

func (*Finding_FindingInfo) MergeMisconfigurationFindingInfo

func (t *Finding_FindingInfo) MergeMisconfigurationFindingInfo(v MisconfigurationFindingInfo) error

MergeMisconfigurationFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided MisconfigurationFindingInfo

func (*Finding_FindingInfo) MergePackageFindingInfo

func (t *Finding_FindingInfo) MergePackageFindingInfo(v PackageFindingInfo) error

MergePackageFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided PackageFindingInfo

func (*Finding_FindingInfo) MergeRootkitFindingInfo

func (t *Finding_FindingInfo) MergeRootkitFindingInfo(v RootkitFindingInfo) error

MergeRootkitFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided RootkitFindingInfo

func (*Finding_FindingInfo) MergeSecretFindingInfo

func (t *Finding_FindingInfo) MergeSecretFindingInfo(v SecretFindingInfo) error

MergeSecretFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided SecretFindingInfo

func (*Finding_FindingInfo) MergeVulnerabilityFindingInfo

func (t *Finding_FindingInfo) MergeVulnerabilityFindingInfo(v VulnerabilityFindingInfo) error

MergeVulnerabilityFindingInfo performs a merge with any union data inside the Finding_FindingInfo, using the provided VulnerabilityFindingInfo

func (*Finding_FindingInfo) UnmarshalJSON

func (t *Finding_FindingInfo) UnmarshalJSON(b []byte) error

func (Finding_FindingInfo) ValueByDiscriminator

func (t Finding_FindingInfo) ValueByDiscriminator() (interface{}, error)

type Findings

type Findings struct {
	// Count Total findings count according to the given filters
	Count *int `json:"count,omitempty"`

	// Items List of findings according to the given filters
	Items *[]Finding `json:"items,omitempty"`
}

Findings defines model for Findings.

type GetAssetScanEstimationsAssetScanEstimationIDParams

type GetAssetScanEstimationsAssetScanEstimationIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetAssetScanEstimationsAssetScanEstimationIDParams defines parameters for GetAssetScanEstimationsAssetScanEstimationID.

type GetAssetScanEstimationsParams

type GetAssetScanEstimationsParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetAssetScanEstimationsParams defines parameters for GetAssetScanEstimations.

type GetAssetScansAssetScanIDParams

type GetAssetScansAssetScanIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetAssetScansAssetScanIDParams defines parameters for GetAssetScansAssetScanID.

type GetAssetScansParams

type GetAssetScansParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetAssetScansParams defines parameters for GetAssetScans.

type GetAssetsAssetIDParams

type GetAssetsAssetIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetAssetsAssetIDParams defines parameters for GetAssetsAssetID.

type GetAssetsParams

type GetAssetsParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetAssetsParams defines parameters for GetAssets.

type GetFindingsFindingIDParams

type GetFindingsFindingIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetFindingsFindingIDParams defines parameters for GetFindingsFindingID.

type GetFindingsParams

type GetFindingsParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetFindingsParams defines parameters for GetFindings.

type GetProvidersParams

type GetProvidersParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetProvidersParams defines parameters for GetProviders.

type GetProvidersProviderIDParams

type GetProvidersProviderIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetProvidersProviderIDParams defines parameters for GetProvidersProviderID.

type GetScanConfigsParams

type GetScanConfigsParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetScanConfigsParams defines parameters for GetScanConfigs.

type GetScanConfigsScanConfigIDParams

type GetScanConfigsScanConfigIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetScanConfigsScanConfigIDParams defines parameters for GetScanConfigsScanConfigID.

type GetScanEstimationsParams

type GetScanEstimationsParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetScanEstimationsParams defines parameters for GetScanEstimations.

type GetScanEstimationsScanEstimationIDParams

type GetScanEstimationsScanEstimationIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetScanEstimationsScanEstimationIDParams defines parameters for GetScanEstimationsScanEstimationID.

type GetScansParams

type GetScansParams struct {
	Filter  *OdataFilter `form:"$filter,omitempty" json:"$filter,omitempty"`
	Select  *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Count   *OdataCount  `form:"$count,omitempty" json:"$count,omitempty"`
	Top     *OdataTop    `form:"$top,omitempty" json:"$top,omitempty"`
	Skip    *OdataSkip   `form:"$skip,omitempty" json:"$skip,omitempty"`
	Expand  *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
	OrderBy *OrderBy     `form:"$orderby,omitempty" json:"$orderby,omitempty"`
}

GetScansParams defines parameters for GetScans.

type GetScansScanIDParams

type GetScansScanIDParams struct {
	Select *OdataSelect `form:"$select,omitempty" json:"$select,omitempty"`
	Expand *OdataExpand `form:"$expand,omitempty" json:"$expand,omitempty"`
}

GetScansScanIDParams defines parameters for GetScansScanID.

type Ifmatch

type Ifmatch = int

Ifmatch defines model for ifmatch.

type InfoFinderConfig

type InfoFinderConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

InfoFinderConfig defines model for InfoFinderConfig.

func (*InfoFinderConfig) GetScannersList

func (c *InfoFinderConfig) GetScannersList() []string

func (*InfoFinderConfig) IsEnabled

func (c *InfoFinderConfig) IsEnabled() bool

type InfoFinderFindingInfo

type InfoFinderFindingInfo struct {
	// Data The data found by the scanner in the specific path for a specific type. See example for SSHKnownHostFingerprint info type
	Data       *string `json:"data,omitempty"`
	ObjectType string  `json:"objectType"`

	// Path File path containing the info
	Path        *string   `json:"path,omitempty"`
	ScannerName *string   `json:"scannerName,omitempty"`
	Type        *InfoType `json:"type,omitempty"`
}

InfoFinderFindingInfo defines model for InfoFinderFindingInfo.

type InfoFinderInfo

type InfoFinderInfo struct {
	// Data The data found by the scanner in the specific path for a specific type. See example for SSHKnownHostFingerprint info type
	Data *string `json:"data,omitempty"`

	// Path File path containing the info
	Path        *string   `json:"path,omitempty"`
	ScannerName *string   `json:"scannerName,omitempty"`
	Type        *InfoType `json:"type,omitempty"`
}

InfoFinderInfo defines model for InfoFinderInfo.

type InfoFinderScan

type InfoFinderScan struct {
	Infos    *[]InfoFinderInfo `json:"infos"`
	Scanners *[]string         `json:"scanners"`
	Status   *ScannerStatus    `json:"status,omitempty"`
}

InfoFinderScan defines model for InfoFinderScan.

type InfoType

type InfoType string

InfoType defines model for InfoType.

const (
	InfoTypeSSHAuthorizedKeyFingerprint InfoType = "SSHAuthorizedKeyFingerprint"
	InfoTypeSSHDaemonKeyFingerprint     InfoType = "SSHDaemonKeyFingerprint"
	InfoTypeSSHKnownHostFingerprint     InfoType = "SSHKnownHostFingerprint"
	InfoTypeSSHPrivateKeyFingerprint    InfoType = "SSHPrivateKeyFingerprint"
	InfoTypeUNKNOWN                     InfoType = "UNKNOWN"
)

Defines values for InfoType.

type Malware

type Malware struct {
	MalwareName *string      `json:"malwareName,omitempty"`
	MalwareType *MalwareType `json:"malwareType,omitempty"`

	// Path Path of the file that contains malware
	Path     *string `json:"path,omitempty"`
	RuleName *string `json:"ruleName,omitempty"`
}

Malware defines model for Malware.

type MalwareConfig

type MalwareConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

MalwareConfig defines model for MalwareConfig.

func (*MalwareConfig) GetScannersList

func (c *MalwareConfig) GetScannersList() []string

func (*MalwareConfig) IsEnabled

func (c *MalwareConfig) IsEnabled() bool

type MalwareFindingInfo

type MalwareFindingInfo struct {
	MalwareName *string      `json:"malwareName,omitempty"`
	MalwareType *MalwareType `json:"malwareType,omitempty"`
	ObjectType  string       `json:"objectType"`

	// Path Path of the file that contains malware
	Path     *string `json:"path,omitempty"`
	RuleName *string `json:"ruleName,omitempty"`
}

MalwareFindingInfo defines model for MalwareFindingInfo.

type MalwareScan

type MalwareScan struct {
	Malware  *[]Malware         `json:"malware"`
	Metadata *[]ScannerMetadata `json:"metadata"`
	Status   *ScannerStatus     `json:"status,omitempty"`
}

MalwareScan defines model for MalwareScan.

type MalwareType

type MalwareType = string

MalwareType defines model for MalwareType.

type Metadata

type Metadata struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`
}

Metadata defines model for Metadata.

type MetadataReadOnly

type MetadataReadOnly struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`
}

MetadataReadOnly defines model for MetadataReadOnly.

type Misconfiguration

type Misconfiguration struct {
	Message         *string                   `json:"message,omitempty"`
	Remediation     *string                   `json:"remediation,omitempty"`
	ScannedPath     *string                   `json:"scannedPath,omitempty"`
	ScannerName     *string                   `json:"scannerName,omitempty"`
	Severity        *MisconfigurationSeverity `json:"severity,omitempty"`
	TestCategory    *string                   `json:"testCategory,omitempty"`
	TestDescription *string                   `json:"testDescription,omitempty"`
	TestID          *string                   `json:"testID,omitempty"`
}

Misconfiguration defines model for Misconfiguration.

type MisconfigurationFindingInfo

type MisconfigurationFindingInfo struct {
	Message         *string                   `json:"message,omitempty"`
	ObjectType      string                    `json:"objectType"`
	Remediation     *string                   `json:"remediation,omitempty"`
	ScannedPath     *string                   `json:"scannedPath,omitempty"`
	ScannerName     *string                   `json:"scannerName,omitempty"`
	Severity        *MisconfigurationSeverity `json:"severity,omitempty"`
	TestCategory    *string                   `json:"testCategory,omitempty"`
	TestDescription *string                   `json:"testDescription,omitempty"`
	TestID          *string                   `json:"testID,omitempty"`
}

MisconfigurationFindingInfo defines model for MisconfigurationFindingInfo.

type MisconfigurationScan

type MisconfigurationScan struct {
	Misconfigurations *[]Misconfiguration `json:"misconfigurations"`
	Scanners          *[]string           `json:"scanners"`
	Status            *ScannerStatus      `json:"status,omitempty"`
}

MisconfigurationScan defines model for MisconfigurationScan.

type MisconfigurationSeverity

type MisconfigurationSeverity string

MisconfigurationSeverity defines model for MisconfigurationSeverity.

const (
	MisconfigurationHighSeverity   MisconfigurationSeverity = "MisconfigurationHighSeverity"
	MisconfigurationLowSeverity    MisconfigurationSeverity = "MisconfigurationLowSeverity"
	MisconfigurationMediumSeverity MisconfigurationSeverity = "MisconfigurationMediumSeverity"
)

Defines values for MisconfigurationSeverity.

type MisconfigurationsConfig

type MisconfigurationsConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

MisconfigurationsConfig defines model for MisconfigurationsConfig.

func (*MisconfigurationsConfig) GetScannersList

func (c *MisconfigurationsConfig) GetScannersList() []string

func (*MisconfigurationsConfig) IsEnabled

func (c *MisconfigurationsConfig) IsEnabled() bool

type OdataCount

type OdataCount = bool

OdataCount defines model for odataCount.

type OdataExpand

type OdataExpand = string

OdataExpand defines model for odataExpand.

type OdataFilter

type OdataFilter = string

OdataFilter defines model for odataFilter.

type OdataSelect

type OdataSelect = string

OdataSelect defines model for odataSelect.

type OdataSkip

type OdataSkip = int

OdataSkip defines model for odataSkip.

type OdataTop

type OdataTop = int

OdataTop defines model for odataTop.

type OrderBy

type OrderBy = string

OrderBy defines model for odataOrderBy.

type Package

type Package struct {
	Cpes     *[]string `json:"cpes"`
	Language *string   `json:"language,omitempty"`
	Licenses *[]string `json:"licenses"`
	Name     *string   `json:"name,omitempty"`
	Purl     *string   `json:"purl,omitempty"`
	Type     *string   `json:"type,omitempty"`
	Version  *string   `json:"version,omitempty"`
}

Package defines model for Package.

type PackageFindingInfo

type PackageFindingInfo struct {
	Cpes       *[]string `json:"cpes"`
	Language   *string   `json:"language,omitempty"`
	Licenses   *[]string `json:"licenses"`
	Name       *string   `json:"name,omitempty"`
	ObjectType string    `json:"objectType"`
	Purl       *string   `json:"purl,omitempty"`
	Type       *string   `json:"type,omitempty"`
	Version    *string   `json:"version,omitempty"`
}

PackageFindingInfo defines model for PackageFindingInfo.

type PatchAssetScanEstimationsAssetScanEstimationIDJSONRequestBody

type PatchAssetScanEstimationsAssetScanEstimationIDJSONRequestBody = AssetScanEstimation

PatchAssetScanEstimationsAssetScanEstimationIDJSONRequestBody defines body for PatchAssetScanEstimationsAssetScanEstimationID for application/json ContentType.

type PatchAssetScanEstimationsAssetScanEstimationIDParams

type PatchAssetScanEstimationsAssetScanEstimationIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchAssetScanEstimationsAssetScanEstimationIDParams defines parameters for PatchAssetScanEstimationsAssetScanEstimationID.

type PatchAssetScansAssetScanIDJSONRequestBody

type PatchAssetScansAssetScanIDJSONRequestBody = AssetScan

PatchAssetScansAssetScanIDJSONRequestBody defines body for PatchAssetScansAssetScanID for application/json ContentType.

type PatchAssetScansAssetScanIDParams

type PatchAssetScansAssetScanIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchAssetScansAssetScanIDParams defines parameters for PatchAssetScansAssetScanID.

type PatchAssetsAssetIDJSONRequestBody

type PatchAssetsAssetIDJSONRequestBody = Asset

PatchAssetsAssetIDJSONRequestBody defines body for PatchAssetsAssetID for application/json ContentType.

type PatchAssetsAssetIDParams

type PatchAssetsAssetIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchAssetsAssetIDParams defines parameters for PatchAssetsAssetID.

type PatchFindingsFindingIDJSONRequestBody

type PatchFindingsFindingIDJSONRequestBody = Finding

PatchFindingsFindingIDJSONRequestBody defines body for PatchFindingsFindingID for application/json ContentType.

type PatchProvidersProviderIDJSONRequestBody

type PatchProvidersProviderIDJSONRequestBody = Provider

PatchProvidersProviderIDJSONRequestBody defines body for PatchProvidersProviderID for application/json ContentType.

type PatchProvidersProviderIDParams

type PatchProvidersProviderIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchProvidersProviderIDParams defines parameters for PatchProvidersProviderID.

type PatchScanConfigsScanConfigIDJSONRequestBody

type PatchScanConfigsScanConfigIDJSONRequestBody = ScanConfig

PatchScanConfigsScanConfigIDJSONRequestBody defines body for PatchScanConfigsScanConfigID for application/json ContentType.

type PatchScanConfigsScanConfigIDParams

type PatchScanConfigsScanConfigIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchScanConfigsScanConfigIDParams defines parameters for PatchScanConfigsScanConfigID.

type PatchScanEstimationsScanEstimationIDJSONRequestBody

type PatchScanEstimationsScanEstimationIDJSONRequestBody = ScanEstimation

PatchScanEstimationsScanEstimationIDJSONRequestBody defines body for PatchScanEstimationsScanEstimationID for application/json ContentType.

type PatchScanEstimationsScanEstimationIDParams

type PatchScanEstimationsScanEstimationIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchScanEstimationsScanEstimationIDParams defines parameters for PatchScanEstimationsScanEstimationID.

type PatchScansScanIDJSONRequestBody

type PatchScansScanIDJSONRequestBody = Scan

PatchScansScanIDJSONRequestBody defines body for PatchScansScanID for application/json ContentType.

type PatchScansScanIDParams

type PatchScansScanIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PatchScansScanIDParams defines parameters for PatchScansScanID.

type PodInfo

type PodInfo struct {
	Location   *string `json:"location,omitempty"`
	ObjectType string  `json:"objectType"`
	PodName    *string `json:"podName,omitempty"`
}

PodInfo defines model for PodInfo.

type PostAssetScanEstimationsJSONRequestBody

type PostAssetScanEstimationsJSONRequestBody = AssetScanEstimation

PostAssetScanEstimationsJSONRequestBody defines body for PostAssetScanEstimations for application/json ContentType.

type PostAssetScansJSONRequestBody

type PostAssetScansJSONRequestBody = AssetScan

PostAssetScansJSONRequestBody defines body for PostAssetScans for application/json ContentType.

type PostAssetsJSONRequestBody

type PostAssetsJSONRequestBody = Asset

PostAssetsJSONRequestBody defines body for PostAssets for application/json ContentType.

type PostFindingsJSONRequestBody

type PostFindingsJSONRequestBody = Finding

PostFindingsJSONRequestBody defines body for PostFindings for application/json ContentType.

type PostProvidersJSONRequestBody

type PostProvidersJSONRequestBody = Provider

PostProvidersJSONRequestBody defines body for PostProviders for application/json ContentType.

type PostScanConfigsJSONRequestBody

type PostScanConfigsJSONRequestBody = ScanConfig

PostScanConfigsJSONRequestBody defines body for PostScanConfigs for application/json ContentType.

type PostScanEstimationsJSONRequestBody

type PostScanEstimationsJSONRequestBody = ScanEstimation

PostScanEstimationsJSONRequestBody defines body for PostScanEstimations for application/json ContentType.

type PostScansJSONRequestBody

type PostScansJSONRequestBody = Scan

PostScansJSONRequestBody defines body for PostScans for application/json ContentType.

type Provider

type Provider struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// DisplayName Human-readable name for the provider.
	DisplayName *string `json:"displayName,omitempty"`
	Id          *string `json:"id,omitempty"`

	// LastHeartbeatTime Timestamp of the last heartbeat from the provider.
	LastHeartbeatTime *time.Time `json:"lastHeartbeatTime,omitempty"`

	// ProviderRuntimeVersion Version of the provider runtime that the provider was compiled with.
	ProviderRuntimeVersion *string         `json:"providerRuntimeVersion,omitempty"`
	Revision               *int            `json:"revision,omitempty"`
	Status                 *ProviderStatus `json:"status,omitempty"`
}

Provider defines model for Provider.

type ProviderExists

type ProviderExists struct {
	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`

	// Provider Describes a provider object.
	Provider *Provider `json:"provider,omitempty"`
}

ProviderExists defines model for ProviderExists.

type ProviderID

type ProviderID = string

ProviderID defines model for providerID.

type ProviderRelationship

type ProviderRelationship struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// DisplayName Human-readable name for the provider.
	DisplayName *string `json:"displayName,omitempty"`
	Id          *string `json:"id,omitempty"`

	// LastHeartbeatTime Timestamp of the last heartbeat from the provider.
	LastHeartbeatTime *time.Time `json:"lastHeartbeatTime,omitempty"`

	// ProviderRuntimeVersion Version of the provider runtime that the provider was compiled with.
	ProviderRuntimeVersion *string         `json:"providerRuntimeVersion,omitempty"`
	Revision               *int            `json:"revision,omitempty"`
	Status                 *ProviderStatus `json:"status,omitempty"`
}

ProviderRelationship defines model for ProviderRelationship.

type ProviderStatus

type ProviderStatus struct {
	// LastTransitionTime Last date-time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human-readable message indicating details about the last state transition.
	Message *string `json:"message,omitempty"`

	// Reason Machine-readable, UpperCamelCase text indicating the reason for the condition's last transition.
	Reason ProviderStatusReason `json:"reason"`

	// State Describes the health state of the provider.
	//
	// | State     | Description                                    |
	// | --------- | ---------------------------------------------- |
	// | Healthy   | Provider is healthy.                           |
	// | Unhealthy | Heartbeat received, but Provider is unhealthy. |
	// | Unknown   | No heartbeat received from Provider.           |
	State ProviderStatusState `json:"state"`
}

ProviderStatus defines model for ProviderStatus.

type ProviderStatusReason

type ProviderStatusReason string

ProviderStatusReason Machine-readable, UpperCamelCase text indicating the reason for the condition's last transition.

const (
	HeartbeatReceived   ProviderStatusReason = "HeartbeatReceived"
	NoHeartbeatReceived ProviderStatusReason = "NoHeartbeatReceived"
)

Defines values for ProviderStatusReason.

type ProviderStatusState

type ProviderStatusState string

ProviderStatusState Describes the health state of the provider.

| State | Description | | --------- | ---------------------------------------------- | | Healthy | Provider is healthy. | | Unhealthy | Heartbeat received, but Provider is unhealthy. | | Unknown | No heartbeat received from Provider. |

const (
	ProviderStatusStateHealthy   ProviderStatusState = "Healthy"
	ProviderStatusStateUnhealthy ProviderStatusState = "Unhealthy"
	ProviderStatusStateUnknown   ProviderStatusState = "Unknown"
)

Defines values for ProviderStatusState.

type Providers

type Providers struct {
	// Count Total providers count according the given filters
	Count *int `json:"count,omitempty"`

	// Items List of providers in the given filters and page. List length must be lower or equal to pageSize.
	Items *[]Provider `json:"items,omitempty"`
}

Providers defines model for Providers.

type PutAssetScanEstimationsAssetScanEstimationIDJSONRequestBody

type PutAssetScanEstimationsAssetScanEstimationIDJSONRequestBody = AssetScanEstimation

PutAssetScanEstimationsAssetScanEstimationIDJSONRequestBody defines body for PutAssetScanEstimationsAssetScanEstimationID for application/json ContentType.

type PutAssetScanEstimationsAssetScanEstimationIDParams

type PutAssetScanEstimationsAssetScanEstimationIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutAssetScanEstimationsAssetScanEstimationIDParams defines parameters for PutAssetScanEstimationsAssetScanEstimationID.

type PutAssetScansAssetScanIDJSONRequestBody

type PutAssetScansAssetScanIDJSONRequestBody = AssetScan

PutAssetScansAssetScanIDJSONRequestBody defines body for PutAssetScansAssetScanID for application/json ContentType.

type PutAssetScansAssetScanIDParams

type PutAssetScansAssetScanIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutAssetScansAssetScanIDParams defines parameters for PutAssetScansAssetScanID.

type PutAssetsAssetIDJSONRequestBody

type PutAssetsAssetIDJSONRequestBody = Asset

PutAssetsAssetIDJSONRequestBody defines body for PutAssetsAssetID for application/json ContentType.

type PutAssetsAssetIDParams

type PutAssetsAssetIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutAssetsAssetIDParams defines parameters for PutAssetsAssetID.

type PutFindingsFindingIDJSONRequestBody

type PutFindingsFindingIDJSONRequestBody = Finding

PutFindingsFindingIDJSONRequestBody defines body for PutFindingsFindingID for application/json ContentType.

type PutProvidersProviderIDJSONRequestBody

type PutProvidersProviderIDJSONRequestBody = Provider

PutProvidersProviderIDJSONRequestBody defines body for PutProvidersProviderID for application/json ContentType.

type PutProvidersProviderIDParams

type PutProvidersProviderIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutProvidersProviderIDParams defines parameters for PutProvidersProviderID.

type PutScanConfigsScanConfigIDJSONRequestBody

type PutScanConfigsScanConfigIDJSONRequestBody = ScanConfig

PutScanConfigsScanConfigIDJSONRequestBody defines body for PutScanConfigsScanConfigID for application/json ContentType.

type PutScanConfigsScanConfigIDParams

type PutScanConfigsScanConfigIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutScanConfigsScanConfigIDParams defines parameters for PutScanConfigsScanConfigID.

type PutScanEstimationsScanEstimationIDJSONRequestBody

type PutScanEstimationsScanEstimationIDJSONRequestBody = ScanEstimation

PutScanEstimationsScanEstimationIDJSONRequestBody defines body for PutScanEstimationsScanEstimationID for application/json ContentType.

type PutScanEstimationsScanEstimationIDParams

type PutScanEstimationsScanEstimationIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutScanEstimationsScanEstimationIDParams defines parameters for PutScanEstimationsScanEstimationID.

type PutScansScanIDJSONRequestBody

type PutScansScanIDJSONRequestBody = Scan

PutScansScanIDJSONRequestBody defines body for PutScansScanID for application/json ContentType.

type PutScansScanIDParams

type PutScansScanIDParams struct {
	IfMatch *Ifmatch `json:"If-Match,omitempty"`
}

PutScansScanIDParams defines parameters for PutScansScanID.

type ResourceCleanupStatus

type ResourceCleanupStatus struct {
	// LastTransitionTime Last date time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human readable message.
	Message *string `json:"message,omitempty"`

	// Reason Machine readable reason for state transition.
	//
	// | State   | Reason          | Description                                                            |
	// | ------- | --------------- | ---------------------------------------------------------------------- |
	// | Pending | AssetScanCreate | AssetScan created                                                      |
	// | Skipped | NotApplicable   | Resource cleanup is not required as it is managed outside of VMClarity |
	// | Skipped | DeletePolicy    | Resource cleanup has been skipped due to Delete Job Policy             |
	// | Failed  | ProviderError   | Failed due to Provider error                                           |
	// | Failed  | InternalError   | Failed due to internal error                                           |
	// | Done    | Success         | Successfully completed                                                 |
	Reason ResourceCleanupStatusReason `json:"reason"`

	// State Describes the state of resource cleanup.
	//
	// | State   | Description                                                |
	// | ------- | ---------------------------------------------------------- |
	// | Pending | Initial state for cleaning up resources                    |
	// | Skipped | Resource cleanup has been skipped due to Delete Job Policy |
	// | Failed  | Cleaning up resources has been failed                      |
	// | Done    | Resources have been successfully cleaned up                |
	State ResourceCleanupStatusState `json:"state"`
}

ResourceCleanupStatus defines model for ResourceCleanupStatus.

func (*ResourceCleanupStatus) Equals

func (*ResourceCleanupStatus) IsValidTransition

func (a *ResourceCleanupStatus) IsValidTransition(b ResourceCleanupStatus) error

type ResourceCleanupStatusReason

type ResourceCleanupStatusReason string

ResourceCleanupStatusReason Machine readable reason for state transition.

| State | Reason | Description | | ------- | --------------- | ---------------------------------------------------------------------- | | Pending | AssetScanCreate | AssetScan created | | Skipped | NotApplicable | Resource cleanup is not required as it is managed outside of VMClarity | | Skipped | DeletePolicy | Resource cleanup has been skipped due to Delete Job Policy | | Failed | ProviderError | Failed due to Provider error | | Failed | InternalError | Failed due to internal error | | Done | Success | Successfully completed |

const (
	ResourceCleanupStatusReasonAssetScanCreated ResourceCleanupStatusReason = "AssetScanCreated"
	ResourceCleanupStatusReasonDeletePolicy     ResourceCleanupStatusReason = "DeletePolicy"
	ResourceCleanupStatusReasonInternalError    ResourceCleanupStatusReason = "InternalError"
	ResourceCleanupStatusReasonNotApplicable    ResourceCleanupStatusReason = "NotApplicable"
	ResourceCleanupStatusReasonProviderError    ResourceCleanupStatusReason = "ProviderError"
	ResourceCleanupStatusReasonSuccess          ResourceCleanupStatusReason = "Success"
)

Defines values for ResourceCleanupStatusReason.

type ResourceCleanupStatusState

type ResourceCleanupStatusState string

ResourceCleanupStatusState Describes the state of resource cleanup.

| State | Description | | ------- | ---------------------------------------------------------- | | Pending | Initial state for cleaning up resources | | Skipped | Resource cleanup has been skipped due to Delete Job Policy | | Failed | Cleaning up resources has been failed | | Done | Resources have been successfully cleaned up |

const (
	ResourceCleanupStatusStateDone    ResourceCleanupStatusState = "Done"
	ResourceCleanupStatusStateFailed  ResourceCleanupStatusState = "Failed"
	ResourceCleanupStatusStatePending ResourceCleanupStatusState = "Pending"
	ResourceCleanupStatusStateSkipped ResourceCleanupStatusState = "Skipped"
)

Defines values for ResourceCleanupStatusState.

type RootVolume

type RootVolume struct {
	Encrypted RootVolumeEncrypted `json:"encrypted"`
	SizeGB    int                 `json:"sizeGB"`
}

RootVolume Information about VM root volume

type RootVolumeEncrypted

type RootVolumeEncrypted string

RootVolumeEncrypted defines model for RootVolume.Encrypted.

const (
	RootVolumeEncryptedNo      RootVolumeEncrypted = "No"
	RootVolumeEncryptedUnknown RootVolumeEncrypted = "Unknown"
	RootVolumeEncryptedYes     RootVolumeEncrypted = "Yes"
)

Defines values for RootVolumeEncrypted.

type Rootkit

type Rootkit struct {
	Message     *string      `json:"message,omitempty"`
	RootkitName *string      `json:"rootkitName,omitempty"`
	RootkitType *RootkitType `json:"rootkitType,omitempty"`
}

Rootkit defines model for Rootkit.

type RootkitFindingInfo

type RootkitFindingInfo struct {
	Message     *string      `json:"message,omitempty"`
	ObjectType  string       `json:"objectType"`
	RootkitName *string      `json:"rootkitName,omitempty"`
	RootkitType *RootkitType `json:"rootkitType,omitempty"`
}

RootkitFindingInfo defines model for RootkitFindingInfo.

type RootkitScan

type RootkitScan struct {
	Rootkits *[]Rootkit     `json:"rootkits"`
	Status   *ScannerStatus `json:"status,omitempty"`
}

RootkitScan defines model for RootkitScan.

type RootkitType

type RootkitType string

RootkitType defines model for RootkitType.

const (
	RootkitTypeAPPLICATION RootkitType = "APPLICATION"
	RootkitTypeFIRMWARE    RootkitType = "FIRMWARE"
	RootkitTypeKERNEL      RootkitType = "KERNEL"
	RootkitTypeMEMORY      RootkitType = "MEMORY"
	RootkitTypeUNKNOWN     RootkitType = "UNKNOWN"
)

Defines values for RootkitType.

type RootkitsConfig

type RootkitsConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

RootkitsConfig defines model for RootkitsConfig.

func (*RootkitsConfig) GetScannersList

func (c *RootkitsConfig) GetScannersList() []string

func (*RootkitsConfig) IsEnabled

func (c *RootkitsConfig) IsEnabled() bool

type RuntimeScheduleScanConfig

type RuntimeScheduleScanConfig struct {
	// CronLine Cron schedule expressions.
	CronLine *string `json:"cronLine,omitempty"`

	// OperationTime The next time this ScanConfig should trigger a scan.
	OperationTime *time.Time `json:"operationTime,omitempty"`
}

RuntimeScheduleScanConfig Runtime schedule scan configuration. If only operationTime is set, it will be a single scan scheduled for the operationTime. If only cronLine is set, the current time will be the "from time" to start the scheduling according to the cronLine. If both operationTime and cronLine are set, the first scan will run at operationTime and the operationTime will be the first time that the cronLine will be effective from.

type SBOMConfig

type SBOMConfig struct {
	Analyzers *[]string `json:"analyzers,omitempty"`
	Enabled   *bool     `json:"enabled,omitempty"`
}

SBOMConfig defines model for SBOMConfig.

func (*SBOMConfig) GetAnalyzersList

func (c *SBOMConfig) GetAnalyzersList() []string

func (*SBOMConfig) IsEnabled

func (c *SBOMConfig) IsEnabled() bool

type SbomScan

type SbomScan struct {
	Packages *[]Package     `json:"packages"`
	Status   *ScannerStatus `json:"status,omitempty"`
}

SbomScan defines model for SbomScan.

type Scan

type Scan struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// AssetIDs List of asset IDs to be scanned
	AssetIDs          *[]string          `json:"assetIDs"`
	AssetScanTemplate *AssetScanTemplate `json:"assetScanTemplate,omitempty"`
	EndTime           *time.Time         `json:"endTime,omitempty"`
	Id                *string            `json:"id,omitempty"`

	// MaxParallelScanners The maximum number of asset scans that can be scheduled in parallel for this scan
	MaxParallelScanners *int    `json:"maxParallelScanners,omitempty"`
	Name                *string `json:"name,omitempty"`
	Revision            *int    `json:"revision,omitempty"`

	// ScanConfig Describes a relationship to a scan config which can be expanded.
	ScanConfig *ScanConfigRelationship `json:"scanConfig,omitempty"`

	// Scope The query used to limit the scope of this scan. It uses
	// the ODATA $filter query language to limit the collection of assets
	// that this scan will operate over. For example
	// `startswith(assetInfo.location, 'eu-west-2')` will limit this scan
	// to just assets in the eu-west-2 AWS region.
	Scope     *string     `json:"scope,omitempty"`
	StartTime *time.Time  `json:"startTime,omitempty"`
	Status    *ScanStatus `json:"status,omitempty"`

	// Summary A summary of the progress of a scan for informational purposes.
	Summary *ScanSummary `json:"summary,omitempty"`

	// TimeoutSeconds The maximum time in seconds that a scan started from this config
	// should run for before being automatically aborted.
	TimeoutSeconds *int `json:"timeoutSeconds,omitempty"`
}

Scan defines model for Scan.

func (*Scan) GetID

func (s *Scan) GetID() (string, bool)

func (*Scan) GetMaxParallelScanners

func (s *Scan) GetMaxParallelScanners() int

func (*Scan) GetScope

func (s *Scan) GetScope() (string, bool)

func (*Scan) GetStatus

func (s *Scan) GetStatus() (ScanStatus, bool)

func (*Scan) GetTimeoutSeconds

func (s *Scan) GetTimeoutSeconds() int

func (*Scan) IsTimedOut

func (s *Scan) IsTimedOut(defaultTimeout time.Duration) bool

type ScanConfig

type ScanConfig struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// Disabled if true, the scan config is disabled and no scan should run from it
	Disabled     *bool         `json:"disabled,omitempty"`
	Id           *string       `json:"id,omitempty"`
	Name         *string       `json:"name,omitempty"`
	Revision     *int          `json:"revision,omitempty"`
	ScanTemplate *ScanTemplate `json:"scanTemplate,omitempty"`

	// Scheduled Runtime schedule scan configuration. If only operationTime is set, it will be a single scan scheduled for the operationTime. If only cronLine is set, the current time will be the "from time" to start the scheduling according to the cronLine. If both operationTime and cronLine are set, the first scan will run at operationTime and the operationTime will be the first time that the cronLine will be effective from.
	Scheduled *RuntimeScheduleScanConfig `json:"scheduled,omitempty"`
}

ScanConfig defines model for ScanConfig.

func (*ScanConfig) GetID

func (s *ScanConfig) GetID() (string, bool)

type ScanConfigExists

type ScanConfigExists struct {
	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`

	// ScanConfig Describes a multi-asset scheduled scan config.
	ScanConfig *ScanConfig `json:"scanConfig,omitempty"`
}

ScanConfigExists defines model for ScanConfigExists.

type ScanConfigID

type ScanConfigID = string

ScanConfigID defines model for scanConfigID.

type ScanConfigRelationship

type ScanConfigRelationship struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// Disabled if true, the scan config is disabled and no scan should run from it
	Disabled     *bool         `json:"disabled,omitempty"`
	Id           string        `json:"id"`
	Name         *string       `json:"name,omitempty"`
	Revision     *int          `json:"revision,omitempty"`
	ScanTemplate *ScanTemplate `json:"scanTemplate,omitempty"`

	// Scheduled Runtime schedule scan configuration. If only operationTime is set, it will be a single scan scheduled for the operationTime. If only cronLine is set, the current time will be the "from time" to start the scheduling according to the cronLine. If both operationTime and cronLine are set, the first scan will run at operationTime and the operationTime will be the first time that the cronLine will be effective from.
	Scheduled *RuntimeScheduleScanConfig `json:"scheduled,omitempty"`
}

ScanConfigRelationship defines model for ScanConfigRelationship.

type ScanConfigs

type ScanConfigs struct {
	// Count Total scan config count according to the given filters
	Count *int `json:"count,omitempty"`

	// Items List of scan configs according to the given filters and page. List length must be lower or equal to pageSize.
	Items *[]ScanConfig `json:"items,omitempty"`
}

ScanConfigs defines model for ScanConfigs.

type ScanEstimation

type ScanEstimation struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// AssetIDs List of asset IDs to be estimated
	AssetIDs *[]string `json:"assetIDs,omitempty"`

	// AssetScanEstimations AssetScanEstimations which make up this ScanEstimation
	AssetScanEstimations *[]AssetScanEstimationRelationship `json:"assetScanEstimations,omitempty"`

	// DeleteAfter The time this resource should be deleted. This value is calculated by endTime + ttlSecondsAfterFinished. This should not be set by the user, but use ttlSecondsAfterFinished instead.
	DeleteAfter  *time.Time            `json:"deleteAfter,omitempty"`
	EndTime      *time.Time            `json:"endTime,omitempty"`
	Id           *string               `json:"id,omitempty"`
	Revision     *int                  `json:"revision,omitempty"`
	ScanTemplate *ScanTemplate         `json:"scanTemplate,omitempty"`
	StartTime    *time.Time            `json:"startTime,omitempty"`
	Status       *ScanEstimationStatus `json:"status,omitempty"`

	// Summary A summary of the AssetScanEstimations under this ScanEstimation
	Summary *ScanEstimationSummary `json:"summary,omitempty"`

	// TtlSecondsAfterFinished The duration in seconds this resource should last until it is deleted.
	TTLSecondsAfterFinished *int `json:"ttlSecondsAfterFinished,omitempty"`
}

ScanEstimation defines model for ScanEstimation.

func (*ScanEstimation) GetID

func (s *ScanEstimation) GetID() (string, bool)

func (*ScanEstimation) GetScope

func (s *ScanEstimation) GetScope() (string, bool)

func (*ScanEstimation) GetStatus

func (s *ScanEstimation) GetStatus() (ScanEstimationStatus, bool)

func (*ScanEstimation) IsTimedOut

func (s *ScanEstimation) IsTimedOut(defaultTimeout time.Duration) bool

type ScanEstimationID

type ScanEstimationID = string

ScanEstimationID defines model for scanEstimationID.

type ScanEstimationRelationship

type ScanEstimationRelationship struct {
	Id *string `json:"id,omitempty"`
}

ScanEstimationRelationship defines model for ScanEstimationRelationship.

type ScanEstimationStatus

type ScanEstimationStatus struct {
	// LastTransitionTime Last date time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human readable message.
	Message *string `json:"message,omitempty"`

	// Reason Machine readable reason for state transition.
	//
	// | State      | Reason              | Description                                                       |
	// | ---------- | ------------------- | ----------------------------------------------------------------- |
	// | Pending    | Created             | Initial state for ScanEstimation                                  |
	// | Discovered | SuccessfulDiscovery | Assets to estimate successfully discovered                        |
	// | InProgress | Running             | Scan estimation is currently in progress                          |
	// | Aborted    | Cancellation        | ScanEstimation has been cancelled                                 |
	// | Failed     | Aborted             | ScanEstimation has failed due to abort                            |
	// | Failed     | Error               | ScanEstimation has failed due to an error                         |
	// | Failed     | Timeout             | ScanEstimation has failed due to timeout                          |
	// | Done       | NothingToEstimate   | ScanEstimation has finished because there was nothing to estimate |
	// | Done       | Success             | ScanEstimation has finished successfully                          |
	Reason ScanEstimationStatusReason `json:"reason"`

	// State Describes the state of scan estimation.
	//
	// | State      | Description                              |
	// | ---------- | ---------------------------------------- |
	// | Pending    | Initial state for ScanEstimation         |
	// | Discovered | Assets have been discovered              |
	// | InProgress | Scan estimation is in progress           |
	// | Aborted    | ScanEstimation has aborted               |
	// | Failed     | ScanEstimation has failed                |
	// | Done       | ScanEstimation has finished successfully |
	State ScanEstimationStatusState `json:"state"`
}

ScanEstimationStatus defines model for ScanEstimationStatus.

func (*ScanEstimationStatus) Equals

func (*ScanEstimationStatus) IsValidTransition

func (a *ScanEstimationStatus) IsValidTransition(b ScanEstimationStatus) error

type ScanEstimationStatusReason

type ScanEstimationStatusReason string

ScanEstimationStatusReason Machine readable reason for state transition.

| State | Reason | Description | | ---------- | ------------------- | ----------------------------------------------------------------- | | Pending | Created | Initial state for ScanEstimation | | Discovered | SuccessfulDiscovery | Assets to estimate successfully discovered | | InProgress | Running | Scan estimation is currently in progress | | Aborted | Cancellation | ScanEstimation has been cancelled | | Failed | Aborted | ScanEstimation has failed due to abort | | Failed | Error | ScanEstimation has failed due to an error | | Failed | Timeout | ScanEstimation has failed due to timeout | | Done | NothingToEstimate | ScanEstimation has finished because there was nothing to estimate | | Done | Success | ScanEstimation has finished successfully |

const (
	ScanEstimationStatusReasonAborted             ScanEstimationStatusReason = "Aborted"
	ScanEstimationStatusReasonCancellation        ScanEstimationStatusReason = "Cancellation"
	ScanEstimationStatusReasonCreated             ScanEstimationStatusReason = "Created"
	ScanEstimationStatusReasonError               ScanEstimationStatusReason = "Error"
	ScanEstimationStatusReasonNothingToEstimate   ScanEstimationStatusReason = "NothingToEstimate"
	ScanEstimationStatusReasonRunning             ScanEstimationStatusReason = "EstimationsRunning"
	ScanEstimationStatusReasonSuccess             ScanEstimationStatusReason = "Success"
	ScanEstimationStatusReasonSuccessfulDiscovery ScanEstimationStatusReason = "SuccessfulDiscovery"
	ScanEstimationStatusReasonTimeout             ScanEstimationStatusReason = "TimeOut"
)

Defines values for ScanEstimationStatusReason.

type ScanEstimationStatusState

type ScanEstimationStatusState string

ScanEstimationStatusState Describes the state of scan estimation.

| State | Description | | ---------- | ---------------------------------------- | | Pending | Initial state for ScanEstimation | | Discovered | Assets have been discovered | | InProgress | Scan estimation is in progress | | Aborted | ScanEstimation has aborted | | Failed | ScanEstimation has failed | | Done | ScanEstimation has finished successfully |

const (
	ScanEstimationStatusStateAborted    ScanEstimationStatusState = "Aborted"
	ScanEstimationStatusStateDiscovered ScanEstimationStatusState = "Discovered"
	ScanEstimationStatusStateDone       ScanEstimationStatusState = "Done"
	ScanEstimationStatusStateFailed     ScanEstimationStatusState = "Failed"
	ScanEstimationStatusStateInProgress ScanEstimationStatusState = "InProgress"
	ScanEstimationStatusStatePending    ScanEstimationStatusState = "Pending"
)

Defines values for ScanEstimationStatusState.

type ScanEstimationSummary

type ScanEstimationSummary struct {
	JobsCompleted *int `json:"jobsCompleted,omitempty"`
	JobsLeftToRun *int `json:"jobsLeftToRun,omitempty"`

	// TotalScanCost Total estimated cost of the scan ($)
	TotalScanCost *float32 `json:"totalScanCost,omitempty"`

	// TotalScanSize Total estimated size of the scan (GB)
	TotalScanSize *int `json:"totalScanSize,omitempty"`

	// TotalScanTime Total estimated time the scan will take (seconds)
	TotalScanTime *int `json:"totalScanTime,omitempty"`
}

ScanEstimationSummary A summary of the AssetScanEstimations under this ScanEstimation

type ScanEstimations

type ScanEstimations struct {
	// Count Total ScanEstimations count according to the given filters
	Count *int `json:"count,omitempty"`

	// Items List of ScanEstimations according to the given filters
	Items *[]ScanEstimation `json:"items,omitempty"`
}

ScanEstimations defines model for ScanEstimations.

type ScanExists

type ScanExists struct {
	// Message Describes which unique constraint combination causes the conflict.
	Message *string `json:"message,omitempty"`

	// Scan Describes a multi-asset scheduled scan.
	Scan *Scan `json:"scan,omitempty"`
}

ScanExists defines model for ScanExists.

type ScanFamiliesConfig

type ScanFamiliesConfig struct {
	Exploits          *ExploitsConfig          `json:"exploits,omitempty"`
	InfoFinder        *InfoFinderConfig        `json:"infoFinder,omitempty"`
	Malware           *MalwareConfig           `json:"malware,omitempty"`
	Misconfigurations *MisconfigurationsConfig `json:"misconfigurations,omitempty"`
	Rootkits          *RootkitsConfig          `json:"rootkits,omitempty"`
	Sbom              *SBOMConfig              `json:"sbom,omitempty"`
	Secrets           *SecretsConfig           `json:"secrets,omitempty"`
	Vulnerabilities   *VulnerabilitiesConfig   `json:"vulnerabilities,omitempty"`
}

ScanFamiliesConfig The configuration of the scanner families within a scan config

type ScanFindingsSummary

type ScanFindingsSummary struct {
	TotalExploits          *int `json:"totalExploits,omitempty"`
	TotalInfoFinder        *int `json:"totalInfoFinder,omitempty"`
	TotalMalware           *int `json:"totalMalware,omitempty"`
	TotalMisconfigurations *int `json:"totalMisconfigurations,omitempty"`
	TotalPackages          *int `json:"totalPackages,omitempty"`
	TotalRootkits          *int `json:"totalRootkits,omitempty"`
	TotalSecrets           *int `json:"totalSecrets,omitempty"`

	// TotalVulnerabilities A summary of number of vulnerabilities found per severity.
	TotalVulnerabilities *VulnerabilityScanSummary `json:"totalVulnerabilities,omitempty"`
}

ScanFindingsSummary A summary of the scan findings.

type ScanID

type ScanID = string

ScanID defines model for scanID.

type ScanRelationship

type ScanRelationship struct {
	// Annotations Generic map of string keys and string values to attach arbitrary non-identifying metadata to objects.
	Annotations *Annotations `json:"annotations,omitempty"`

	// AssetIDs List of asset IDs to be scanned
	AssetIDs          *[]string          `json:"assetIDs"`
	AssetScanTemplate *AssetScanTemplate `json:"assetScanTemplate,omitempty"`
	EndTime           *time.Time         `json:"endTime,omitempty"`
	Id                string             `json:"id"`

	// MaxParallelScanners The maximum number of asset scans that can be scheduled in parallel for this scan
	MaxParallelScanners *int    `json:"maxParallelScanners,omitempty"`
	Name                *string `json:"name,omitempty"`
	Revision            *int    `json:"revision,omitempty"`

	// ScanConfig Describes a relationship to a scan config which can be expanded.
	ScanConfig *ScanConfigRelationship `json:"scanConfig,omitempty"`

	// Scope The query used to limit the scope of this scan. It uses
	// the ODATA $filter query language to limit the collection of assets
	// that this scan will operate over. For example
	// `startswith(assetInfo.location, 'eu-west-2')` will limit this scan
	// to just assets in the eu-west-2 AWS region.
	Scope     *string     `json:"scope,omitempty"`
	StartTime *time.Time  `json:"startTime,omitempty"`
	Status    *ScanStatus `json:"status,omitempty"`

	// Summary A summary of the progress of a scan for informational purposes.
	Summary *ScanSummary `json:"summary,omitempty"`

	// TimeoutSeconds The maximum time in seconds that a scan started from this config
	// should run for before being automatically aborted.
	TimeoutSeconds *int `json:"timeoutSeconds,omitempty"`
}

ScanRelationship defines model for ScanRelationship.

func (*ScanRelationship) GetMaxParallelScanners

func (s *ScanRelationship) GetMaxParallelScanners() int

type ScanStatus

type ScanStatus struct {
	// LastTransitionTime Last date time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human readable message.
	Message *string `json:"message,omitempty"`

	// Reason Machine readable reason for state transition.
	//
	// | State      | Reason            | Description                                                |
	// | ---------- | ----------------- | ---------------------------------------------------------- |
	// | Pending    | Created           | Scan is pending as it has been newly created               |
	// | Discovered | AssetsDiscovered  | Assets that fall into the scope of the Scan are discovered |
	// | InProgress | AssetScansRunning | AssetScans are currently running                           |
	// | Aborted    | Cancellation      | AssetScans are being moved to Aborted state                |
	// | Failed     | Cancellation      | AssetScans are in Aborted state                            |
	// | Failed     | Error             | At least one AssetScan has ended with an error             |
	// | Failed     | Timeout           | Scan has been timed out                                    |
	// | Done       | NothingToScan     | There are no assets that need to be scanned                |
	// | Done       | Success           | Scan ended successfully without any errors                 |
	Reason ScanStatusReason `json:"reason"`

	// State Describes the state of Scan.
	//
	// | State      | Description                                                                   |
	// | ---------- | ----------------------------------------------------------------------------- |
	// | Pending    | The initial state when the scan is created, and is working to discover assets |
	// | Discovered | The asset scans have been discovered and are waiting to be scheduled          |
	// | InProgress | The asset scans have been scheduled and the assets are being scanned          |
	// | Aborted    | The scan has been aborted                                                     |
	// | Failed     | One or more assets could not be successfully scanned                          |
	// | Done       | All assets have been scanned successfully                                     |
	State ScanStatusState `json:"state"`
}

ScanStatus defines model for ScanStatus.

func NewScanStatus

func NewScanStatus(s ScanStatusState, r ScanStatusReason, m *string) *ScanStatus

func (*ScanStatus) Equals

func (a *ScanStatus) Equals(b ScanStatus) bool

func (*ScanStatus) IsValidTransition

func (a *ScanStatus) IsValidTransition(b ScanStatus) error

type ScanStatusReason

type ScanStatusReason string

ScanStatusReason Machine readable reason for state transition.

| State | Reason | Description | | ---------- | ----------------- | ---------------------------------------------------------- | | Pending | Created | Scan is pending as it has been newly created | | Discovered | AssetsDiscovered | Assets that fall into the scope of the Scan are discovered | | InProgress | AssetScansRunning | AssetScans are currently running | | Aborted | Cancellation | AssetScans are being moved to Aborted state | | Failed | Cancellation | AssetScans are in Aborted state | | Failed | Error | At least one AssetScan has ended with an error | | Failed | Timeout | Scan has been timed out | | Done | NothingToScan | There are no assets that need to be scanned | | Done | Success | Scan ended successfully without any errors |

const (
	ScanStatusReasonAssetScansRunning ScanStatusReason = "AssetScansRunning"
	ScanStatusReasonAssetsDiscovered  ScanStatusReason = "AssetsDiscovered"
	ScanStatusReasonCancellation      ScanStatusReason = "Cancellation"
	ScanStatusReasonCreated           ScanStatusReason = "Created"
	ScanStatusReasonError             ScanStatusReason = "Error"
	ScanStatusReasonNothingToScan     ScanStatusReason = "NothingToScan"
	ScanStatusReasonSuccess           ScanStatusReason = "Success"
	ScanStatusReasonTimeout           ScanStatusReason = "Timeout"
)

Defines values for ScanStatusReason.

type ScanStatusState

type ScanStatusState string

ScanStatusState Describes the state of Scan.

| State | Description | | ---------- | ----------------------------------------------------------------------------- | | Pending | The initial state when the scan is created, and is working to discover assets | | Discovered | The asset scans have been discovered and are waiting to be scheduled | | InProgress | The asset scans have been scheduled and the assets are being scanned | | Aborted | The scan has been aborted | | Failed | One or more assets could not be successfully scanned | | Done | All assets have been scanned successfully |

const (
	ScanStatusStateAborted    ScanStatusState = "Aborted"
	ScanStatusStateDiscovered ScanStatusState = "Discovered"
	ScanStatusStateDone       ScanStatusState = "Done"
	ScanStatusStateFailed     ScanStatusState = "Failed"
	ScanStatusStateInProgress ScanStatusState = "InProgress"
	ScanStatusStatePending    ScanStatusState = "Pending"
)

Defines values for ScanStatusState.

type ScanSummary

type ScanSummary struct {
	JobsCompleted          *int `json:"jobsCompleted,omitempty"`
	JobsLeftToRun          *int `json:"jobsLeftToRun,omitempty"`
	TotalExploits          *int `json:"totalExploits,omitempty"`
	TotalInfoFinder        *int `json:"totalInfoFinder,omitempty"`
	TotalMalware           *int `json:"totalMalware,omitempty"`
	TotalMisconfigurations *int `json:"totalMisconfigurations,omitempty"`
	TotalPackages          *int `json:"totalPackages,omitempty"`
	TotalRootkits          *int `json:"totalRootkits,omitempty"`
	TotalSecrets           *int `json:"totalSecrets,omitempty"`

	// TotalVulnerabilities A summary of number of vulnerabilities found per severity.
	TotalVulnerabilities *VulnerabilityScanSummary `json:"totalVulnerabilities,omitempty"`
}

ScanSummary defines model for ScanSummary.

type ScanTemplate

type ScanTemplate struct {
	AssetScanTemplate *AssetScanTemplate `json:"assetScanTemplate,omitempty"`

	// MaxParallelScanners The maximum number of asset scans that can be scheduled in parallel for this scan
	MaxParallelScanners *int `json:"maxParallelScanners,omitempty"`

	// Scope The query used to limit the scope of this scan. It uses
	// the ODATA $filter query language to limit the collection of assets
	// that this scan will operate over. For example
	// `startswith(assetInfo.location, 'eu-west-2')` will limit this scan
	// to just assets in the eu-west-2 AWS region.
	Scope *string `json:"scope,omitempty"`

	// TimeoutSeconds The maximum time in seconds that a scan started from this config
	// should run for before being automatically aborted.
	TimeoutSeconds *int `json:"timeoutSeconds,omitempty"`
}

ScanTemplate defines model for ScanTemplate.

type ScanTemplateReadOnly

type ScanTemplateReadOnly struct {
	AssetScanTemplate *AssetScanTemplate `json:"assetScanTemplate,omitempty"`

	// MaxParallelScanners The maximum number of asset scans that can be scheduled in parallel for this scan
	MaxParallelScanners *int `json:"maxParallelScanners,omitempty"`

	// Scope The query used to limit the scope of this scan. It uses
	// the ODATA $filter query language to limit the collection of assets
	// that this scan will operate over. For example
	// `startswith(assetInfo.location, 'eu-west-2')` will limit this scan
	// to just assets in the eu-west-2 AWS region.
	Scope *string `json:"scope,omitempty"`

	// TimeoutSeconds The maximum time in seconds that a scan started from this config
	// should run for before being automatically aborted.
	TimeoutSeconds *int `json:"timeoutSeconds,omitempty"`
}

ScanTemplateReadOnly defines model for ScanTemplateReadOnly.

type ScanType

type ScanType string

ScanType defines model for ScanType.

const (
	EXPLOIT          ScanType = "EXPLOIT"
	INFOFINDER       ScanType = "INFOFINDER"
	MALWARE          ScanType = "MALWARE"
	MISCONFIGURATION ScanType = "MISCONFIGURATION"
	ROOTKIT          ScanType = "ROOTKIT"
	SBOM             ScanType = "SBOM"
	SECRET           ScanType = "SECRET"
	VULNERABILITY    ScanType = "VULNERABILITY"
)

Defines values for ScanType.

type ScannerInstanceCreationConfig

type ScannerInstanceCreationConfig struct {
	MaxPrice         *string `json:"maxPrice,omitempty"`
	RetryMaxAttempts *int    `json:"retryMaxAttempts,omitempty"`
	UseSpotInstances bool    `json:"useSpotInstances"`
}

ScannerInstanceCreationConfig Configuration of scanner instance

type ScannerMetadata

type ScannerMetadata struct {
	ScannerName    *string         `json:"scannerName,omitempty"`
	ScannerSummary *ScannerSummary `json:"scannerSummary,omitempty"`
}

ScannerMetadata defines model for ScannerMetadata.

type ScannerStatus

type ScannerStatus struct {
	// LastTransitionTime Last date time when the status has changed.
	LastTransitionTime time.Time `json:"lastTransitionTime"`

	// Message Human readable message.
	Message *string `json:"message,omitempty"`

	// Reason Machine readable reason for state transition.
	//
	// | State      | Reason            | Description                                 |
	// | ---------- | ----------------- | ------------------------------------------- |
	// | Pending    | Scheduled         | Scanner has been enabled in ScanConfig      |
	// | InProgress | Scanning          | Scanner is currently running                |
	// | Skipped    | NotScheduled      | Scanner hasn't been enabled in ScanConfig   |
	// | Failed     | Error             | Scanner finished with an error              |
	// | Done       | Success           | Scanner finished successfully               |
	Reason ScannerStatusReason `json:"reason"`

	// State Describes the state of a scanner on the asset.
	//
	// | State       | Description                                                              |
	// | ----------- | ------------------------------------------------------------------------ |
	// | Pending     | Scanner is pending and waits for state transition to InProgress state    |
	// | InProgress  | Scanning is being performed                                              |
	// | Skipped     | Scanner is **not** scheduled                                             |
	// | Failed      | Scanner has failed, check *reason* and *message* fields for the details  |
	// | Done        | Scanner has finished scanning with no errors                             |
	State ScannerStatusState `json:"state"`
}

ScannerStatus defines model for ScannerStatus.

type ScannerStatusReason

type ScannerStatusReason string

ScannerStatusReason Machine readable reason for state transition.

| State | Reason | Description | | ---------- | ----------------- | ------------------------------------------- | | Pending | Scheduled | Scanner has been enabled in ScanConfig | | InProgress | Scanning | Scanner is currently running | | Skipped | NotScheduled | Scanner hasn't been enabled in ScanConfig | | Failed | Error | Scanner finished with an error | | Done | Success | Scanner finished successfully |

const (
	ScannerStatusReasonError        ScannerStatusReason = "Error"
	ScannerStatusReasonNotScheduled ScannerStatusReason = "NotScheduled"
	ScannerStatusReasonScanning     ScannerStatusReason = "Scanning"
	ScannerStatusReasonScheduled    ScannerStatusReason = "Scheduled"
	ScannerStatusReasonSuccess      ScannerStatusReason = "Success"
)

Defines values for ScannerStatusReason.

type ScannerStatusState

type ScannerStatusState string

ScannerStatusState Describes the state of a scanner on the asset.

| State | Description | | ----------- | ------------------------------------------------------------------------ | | Pending | Scanner is pending and waits for state transition to InProgress state | | InProgress | Scanning is being performed | | Skipped | Scanner is **not** scheduled | | Failed | Scanner has failed, check *reason* and *message* fields for the details | | Done | Scanner has finished scanning with no errors |

const (
	ScannerStatusStateDone       ScannerStatusState = "Done"
	ScannerStatusStateFailed     ScannerStatusState = "Failed"
	ScannerStatusStateInProgress ScannerStatusState = "InProgress"
	ScannerStatusStatePending    ScannerStatusState = "Pending"
	ScannerStatusStateSkipped    ScannerStatusState = "Skipped"
)

Defines values for ScannerStatusState.

type ScannerSummary

type ScannerSummary struct {
	DataRead           *string `json:"DataRead,omitempty"`
	DataScanned        *string `json:"DataScanned,omitempty"`
	EngineVersion      *string `json:"EngineVersion,omitempty"`
	InfectedFiles      *int    `json:"InfectedFiles,omitempty"`
	KnownViruses       *int    `json:"KnownViruses,omitempty"`
	ScannedDirectories *int    `json:"ScannedDirectories,omitempty"`
	ScannedFiles       *int    `json:"ScannedFiles,omitempty"`
	SuspectedFiles     *int    `json:"SuspectedFiles,omitempty"`
	TimeTaken          *string `json:"TimeTaken,omitempty"`
}

ScannerSummary defines model for ScannerSummary.

type Scans

type Scans struct {
	// Count Total scans count according to the given filters
	Count *int `json:"count,omitempty"`

	// Items List of scans according to the given filters and page. List length must be lower or equal to pageSize.
	Items *[]Scan `json:"items,omitempty"`
}

Scans defines model for Scans.

type Secret

type Secret struct {
	Description *string `json:"description,omitempty"`
	EndColumn   *int    `json:"endColumn,omitempty"`
	EndLine     *int    `json:"endLine,omitempty"`

	// FilePath Name of the file containing the secret
	FilePath *string `json:"filePath,omitempty"`

	// Fingerprint Note: this is not unique
	Fingerprint *string `json:"fingerprint,omitempty"`
	StartColumn *int    `json:"startColumn,omitempty"`
	StartLine   *int    `json:"startLine,omitempty"`
}

Secret defines model for Secret.

type SecretFindingInfo

type SecretFindingInfo struct {
	Description *string `json:"description,omitempty"`
	EndColumn   *int    `json:"endColumn,omitempty"`
	EndLine     *int    `json:"endLine,omitempty"`

	// FilePath Name of the file containing the secret
	FilePath *string `json:"filePath,omitempty"`

	// Fingerprint Note: this is not unique
	Fingerprint *string `json:"fingerprint,omitempty"`
	ObjectType  string  `json:"objectType"`
	StartColumn *int    `json:"startColumn,omitempty"`
	StartLine   *int    `json:"startLine,omitempty"`
}

SecretFindingInfo defines model for SecretFindingInfo.

type SecretScan

type SecretScan struct {
	Secrets *[]Secret      `json:"secrets"`
	Status  *ScannerStatus `json:"status,omitempty"`
}

SecretScan defines model for SecretScan.

type SecretsConfig

type SecretsConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

SecretsConfig defines model for SecretsConfig.

func (*SecretsConfig) GetScannersList

func (c *SecretsConfig) GetScannersList() []string

func (*SecretsConfig) IsEnabled

func (c *SecretsConfig) IsEnabled() bool

type SecurityGroup

type SecurityGroup struct {
	Id string `json:"id"`
}

SecurityGroup general cloud security group

type Success

type Success = SuccessResponse

Success An object that is returned in cases of success that returns nothing.

type SuccessResponse

type SuccessResponse struct {
	Message *string `json:"message,omitempty"`
}

SuccessResponse An object that is returned in cases of success that returns nothing.

type Tag

type Tag struct {
	Key   string `json:"key"`
	Value string `json:"value"`
}

Tag general cloud tag / label

type UnknownError

type UnknownError = ApiResponse

UnknownError An object that is returned in all cases of failures.

type VMInfo

type VMInfo struct {
	Image            string         `json:"image"`
	InstanceID       string         `json:"instanceID"`
	InstanceProvider *CloudProvider `json:"instanceProvider,omitempty"`
	InstanceType     string         `json:"instanceType"`
	LaunchTime       time.Time      `json:"launchTime"`
	Location         string         `json:"location"`
	ObjectType       string         `json:"objectType"`
	Platform         string         `json:"platform"`

	// RootVolume Information about VM root volume
	RootVolume     RootVolume       `json:"rootVolume"`
	SecurityGroups *[]SecurityGroup `json:"securityGroups"`
	Tags           *[]Tag           `json:"tags"`
}

VMInfo defines model for VMInfo.

type VulnerabilitiesConfig

type VulnerabilitiesConfig struct {
	Enabled  *bool     `json:"enabled,omitempty"`
	Scanners *[]string `json:"scanners,omitempty"`
}

VulnerabilitiesConfig defines model for VulnerabilitiesConfig.

func (*VulnerabilitiesConfig) GetScannersList

func (c *VulnerabilitiesConfig) GetScannersList() []string

func (*VulnerabilitiesConfig) IsEnabled

func (c *VulnerabilitiesConfig) IsEnabled() bool

type Vulnerability

type Vulnerability struct {
	Cvss        *[]VulnerabilityCvss `json:"cvss"`
	Description *string              `json:"description,omitempty"`

	// Distro Distro provides information about a detected Linux distribution.
	Distro            *VulnerabilityDistro   `json:"distro,omitempty"`
	Fix               *VulnerabilityFix      `json:"fix,omitempty"`
	LayerId           *string                `json:"layerId,omitempty"`
	Links             *[]string              `json:"links"`
	Package           *Package               `json:"package,omitempty"`
	Path              *string                `json:"path,omitempty"`
	Severity          *VulnerabilitySeverity `json:"severity,omitempty"`
	VulnerabilityName *string                `json:"vulnerabilityName,omitempty"`
}

Vulnerability defines model for Vulnerability.

type VulnerabilityCvss

type VulnerabilityCvss struct {
	Metrics *VulnerabilityCvssMetrics `json:"metrics,omitempty"`
	Vector  *string                   `json:"vector,omitempty"`
	Version *string                   `json:"version,omitempty"`
}

VulnerabilityCvss defines model for VulnerabilityCvss.

type VulnerabilityCvssMetrics

type VulnerabilityCvssMetrics struct {
	BaseScore           *float32 `json:"baseScore,omitempty"`
	ExploitabilityScore *float32 `json:"exploitabilityScore,omitempty"`
	ImpactScore         *float32 `json:"impactScore,omitempty"`
}

VulnerabilityCvssMetrics defines model for VulnerabilityCvssMetrics.

type VulnerabilityDistro

type VulnerabilityDistro struct {
	// IDLike the ID_LIKE field found within the /etc/os-release file
	IDLike *[]string `json:"IDLike"`

	// Name Name of the Linux distribution
	Name *string `json:"name,omitempty"`

	// Version Version of the Linux distribution (major or major.minor version)
	Version *string `json:"version,omitempty"`
}

VulnerabilityDistro Distro provides information about a detected Linux distribution.

type VulnerabilityFindingInfo

type VulnerabilityFindingInfo struct {
	Cvss        *[]VulnerabilityCvss `json:"cvss"`
	Description *string              `json:"description,omitempty"`

	// Distro Distro provides information about a detected Linux distribution.
	Distro            *VulnerabilityDistro   `json:"distro,omitempty"`
	Fix               *VulnerabilityFix      `json:"fix,omitempty"`
	LayerId           *string                `json:"layerId,omitempty"`
	Links             *[]string              `json:"links"`
	ObjectType        string                 `json:"objectType"`
	Package           *Package               `json:"package,omitempty"`
	Path              *string                `json:"path,omitempty"`
	Severity          *VulnerabilitySeverity `json:"severity,omitempty"`
	VulnerabilityName *string                `json:"vulnerabilityName,omitempty"`
}

VulnerabilityFindingInfo defines model for VulnerabilityFindingInfo.

type VulnerabilityFix

type VulnerabilityFix struct {
	State    *string   `json:"state,omitempty"`
	Versions *[]string `json:"versions"`
}

VulnerabilityFix defines model for VulnerabilityFix.

type VulnerabilityScan

type VulnerabilityScan struct {
	Status          *ScannerStatus   `json:"status,omitempty"`
	Vulnerabilities *[]Vulnerability `json:"vulnerabilities"`
}

VulnerabilityScan defines model for VulnerabilityScan.

type VulnerabilityScanSummary

type VulnerabilityScanSummary struct {
	TotalCriticalVulnerabilities   *int `json:"totalCriticalVulnerabilities,omitempty"`
	TotalHighVulnerabilities       *int `json:"totalHighVulnerabilities,omitempty"`
	TotalLowVulnerabilities        *int `json:"totalLowVulnerabilities,omitempty"`
	TotalMediumVulnerabilities     *int `json:"totalMediumVulnerabilities,omitempty"`
	TotalNegligibleVulnerabilities *int `json:"totalNegligibleVulnerabilities,omitempty"`
}

VulnerabilityScanSummary A summary of number of vulnerabilities found per severity.

type VulnerabilitySeverity

type VulnerabilitySeverity string

VulnerabilitySeverity defines model for VulnerabilitySeverity.

const (
	CRITICAL   VulnerabilitySeverity = "CRITICAL"
	HIGH       VulnerabilitySeverity = "HIGH"
	LOW        VulnerabilitySeverity = "LOW"
	MEDIUM     VulnerabilitySeverity = "MEDIUM"
	NEGLIGIBLE VulnerabilitySeverity = "NEGLIGIBLE"
)

Defines values for VulnerabilitySeverity.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL