#[repr(i32)]
pub enum Code {
Show 41 variants Unspecified = 0, InternalError = 1, AppengineApiBackendError = 2, AppengineApiNotAccessible = 3, AppengineDefaultHostMissing = 4, CannotUseGoogleComAccount = 6, CannotUseOwnerAccount = 7, ComputeApiBackendError = 8, ComputeApiNotAccessible = 9, CustomLoginUrlDoesNotBelongToCurrentProject = 10, CustomLoginUrlMalformed = 11, CustomLoginUrlMappedToNonRoutableAddress = 12, CustomLoginUrlMappedToUnreservedAddress = 13, CustomLoginUrlHasNonRoutableIpAddress = 14, CustomLoginUrlHasUnreservedIpAddress = 15, DuplicateScanName = 16, InvalidFieldValue = 18, FailedToAuthenticateToTarget = 19, FindingTypeUnspecified = 20, ForbiddenToScanCompute = 21, ForbiddenUpdateToManagedScan = 43, MalformedFilter = 22, MalformedResourceName = 23, ProjectInactive = 24, RequiredField = 25, ResourceNameInconsistent = 26, ScanAlreadyRunning = 27, ScanNotRunning = 28, SeedUrlDoesNotBelongToCurrentProject = 29, SeedUrlMalformed = 30, SeedUrlMappedToNonRoutableAddress = 31, SeedUrlMappedToUnreservedAddress = 32, SeedUrlHasNonRoutableIpAddress = 33, SeedUrlHasUnreservedIpAddress = 35, ServiceAccountNotConfigured = 36, TooManyScans = 37, UnableToResolveProjectInfo = 38, UnsupportedBlacklistPatternFormat = 39, UnsupportedFilter = 40, UnsupportedFindingType = 41, UnsupportedUrlScheme = 42,
}
Expand description

Output only. Defines an error reason code. Next id: 44

Variants§

§

Unspecified = 0

There is no error.

§

InternalError = 1

Indicates an internal server error. Please DO NOT USE THIS ERROR CODE unless the root cause is truly unknown.

§

AppengineApiBackendError = 2

One of the seed URLs is an App Engine URL but we cannot validate the scan settings due to an App Engine API backend error.

§

AppengineApiNotAccessible = 3

One of the seed URLs is an App Engine URL but we cannot access the App Engine API to validate scan settings.

§

AppengineDefaultHostMissing = 4

One of the seed URLs is an App Engine URL but the Default Host of the App Engine is not set.

§

CannotUseGoogleComAccount = 6

Google corporate accounts can not be used for scanning.

§

CannotUseOwnerAccount = 7

The account of the scan creator can not be used for scanning.

§

ComputeApiBackendError = 8

This scan targets Compute Engine, but we cannot validate scan settings due to a Compute Engine API backend error.

§

ComputeApiNotAccessible = 9

This scan targets Compute Engine, but we cannot access the Compute Engine API to validate the scan settings.

§

CustomLoginUrlDoesNotBelongToCurrentProject = 10

The Custom Login URL does not belong to the current project.

§

CustomLoginUrlMalformed = 11

The Custom Login URL is malformed (can not be parsed).

§

CustomLoginUrlMappedToNonRoutableAddress = 12

The Custom Login URL is mapped to a non-routable IP address in DNS.

§

CustomLoginUrlMappedToUnreservedAddress = 13

The Custom Login URL is mapped to an IP address which is not reserved for the current project.

§

CustomLoginUrlHasNonRoutableIpAddress = 14

The Custom Login URL has a non-routable IP address.

§

CustomLoginUrlHasUnreservedIpAddress = 15

The Custom Login URL has an IP address which is not reserved for the current project.

§

DuplicateScanName = 16

Another scan with the same name (case-sensitive) already exists.

§

InvalidFieldValue = 18

A field is set to an invalid value.

§

FailedToAuthenticateToTarget = 19

There was an error trying to authenticate to the scan target.

§

FindingTypeUnspecified = 20

Finding type value is not specified in the list findings request.

§

ForbiddenToScanCompute = 21

Scan targets Compute Engine, yet current project was not whitelisted for Google Compute Engine Scanning Alpha access.

§

ForbiddenUpdateToManagedScan = 43

User tries to update managed scan

§

MalformedFilter = 22

The supplied filter is malformed. For example, it can not be parsed, does not have a filter type in expression, or the same filter type appears more than once.

§

MalformedResourceName = 23

The supplied resource name is malformed (can not be parsed).

§

ProjectInactive = 24

The current project is not in an active state.

§

RequiredField = 25

A required field is not set.

§

ResourceNameInconsistent = 26

Project id, scanconfig id, scanrun id, or finding id are not consistent with each other in resource name.

§

ScanAlreadyRunning = 27

The scan being requested to start is already running.

§

ScanNotRunning = 28

The scan that was requested to be stopped is not running.

§

SeedUrlDoesNotBelongToCurrentProject = 29

One of the seed URLs does not belong to the current project.

§

SeedUrlMalformed = 30

One of the seed URLs is malformed (can not be parsed).

§

SeedUrlMappedToNonRoutableAddress = 31

One of the seed URLs is mapped to a non-routable IP address in DNS.

§

SeedUrlMappedToUnreservedAddress = 32

One of the seed URLs is mapped to an IP address which is not reserved for the current project.

§

SeedUrlHasNonRoutableIpAddress = 33

One of the seed URLs has on-routable IP address.

§

SeedUrlHasUnreservedIpAddress = 35

One of the seed URLs has an IP address that is not reserved for the current project.

§

ServiceAccountNotConfigured = 36

The Web Security Scanner service account is not configured under the project.

§

TooManyScans = 37

A project has reached the maximum number of scans.

§

UnableToResolveProjectInfo = 38

Resolving the details of the current project fails.

§

UnsupportedBlacklistPatternFormat = 39

One or more blacklist patterns were in the wrong format.

§

UnsupportedFilter = 40

The supplied filter is not supported.

§

UnsupportedFindingType = 41

The supplied finding type is not supported. For example, we do not provide findings of the given finding type.

§

UnsupportedUrlScheme = 42

The URL scheme of one or more of the supplied URLs is not supported.

Implementations§

source§

impl Code

source

pub fn is_valid(value: i32) -> bool

Returns true if value is a variant of Code.

source

pub fn from_i32(value: i32) -> Option<Code>

👎Deprecated: Use the TryFrom<i32> implementation instead

Converts an i32 to a Code, or None if value is not a valid variant.

source§

impl Code

source

pub fn as_str_name(&self) -> &'static str

String value of the enum field names used in the ProtoBuf definition.

The values are not transformed in any way and thus are considered stable (if the ProtoBuf definition does not change) and safe for programmatic use.

source

pub fn from_str_name(value: &str) -> Option<Self>

Creates an enum from field names used in the ProtoBuf definition.

Trait Implementations§

source§

impl Clone for Code

source§

fn clone(&self) -> Code

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

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

Performs copy-assignment from source. Read more
source§

impl Debug for Code

source§

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

Formats the value using the given formatter. Read more
source§

impl Default for Code

source§

fn default() -> Code

Returns the “default value” for a type. Read more
source§

impl From<Code> for i32

source§

fn from(value: Code) -> i32

Converts to this type from the input type.
source§

impl Hash for Code

source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
source§

impl Ord for Code

source§

fn cmp(&self, other: &Code) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized + PartialOrd,

Restrict a value to a certain interval. Read more
source§

impl PartialEq for Code

source§

fn eq(&self, other: &Code) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl PartialOrd for Code

source§

fn partial_cmp(&self, other: &Code) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · source§

fn lt(&self, other: &Rhs) -> bool

This method tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · source§

fn le(&self, other: &Rhs) -> bool

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · source§

fn gt(&self, other: &Rhs) -> bool

This method tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · source§

fn ge(&self, other: &Rhs) -> bool

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more
source§

impl TryFrom<i32> for Code

§

type Error = DecodeError

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

fn try_from(value: i32) -> Result<Code, DecodeError>

Performs the conversion.
source§

impl Copy for Code

source§

impl Eq for Code

source§

impl StructuralPartialEq for Code

Auto Trait Implementations§

§

impl Freeze for Code

§

impl RefUnwindSafe for Code

§

impl Send for Code

§

impl Sync for Code

§

impl Unpin for Code

§

impl UnwindSafe for Code

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
§

impl<Q, K> Comparable<K> for Q
where Q: Ord + ?Sized, K: Borrow<Q> + ?Sized,

§

fn compare(&self, key: &K) -> Ordering

Compare self to key and return their ordering.
source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Checks if this value is equivalent to the given key. Read more
§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

§

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

§

fn from_ref(input: &T) -> T

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

impl<T> Instrument for T

§

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

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

fn in_current_span(self) -> Instrumented<Self>

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

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

source§

fn into(self) -> U

Calls U::from(self).

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

source§

impl<T> IntoRequest<T> for T

source§

fn into_request(self) -> Request<T>

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

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

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

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

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

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

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

§

type Error = Infallible

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

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

Performs the conversion.
source§

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

§

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

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

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

Performs the conversion.
§

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

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

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

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

fn with_current_subscriber(self) -> WithDispatch<Self>

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