scan_config_error.proto 6.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190
  1. // Copyright 2019 Google LLC.
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. //
  15. syntax = "proto3";
  16. package google.cloud.websecurityscanner.v1beta;
  17. option csharp_namespace = "Google.Cloud.WebSecurityScanner.V1Beta";
  18. option go_package = "google.golang.org/genproto/googleapis/cloud/websecurityscanner/v1beta;websecurityscanner";
  19. option java_multiple_files = true;
  20. option java_outer_classname = "ScanConfigErrorProto";
  21. option java_package = "com.google.cloud.websecurityscanner.v1beta";
  22. option php_namespace = "Google\\Cloud\\WebSecurityScanner\\V1beta";
  23. option ruby_package = "Google::Cloud::WebSecurityScanner::V1beta";
  24. // Defines a custom error message used by CreateScanConfig and UpdateScanConfig
  25. // APIs when scan configuration validation fails. It is also reported as part of
  26. // a ScanRunErrorTrace message if scan validation fails due to a scan
  27. // configuration error.
  28. message ScanConfigError {
  29. // Output only.
  30. // Defines an error reason code.
  31. // Next id: 44
  32. enum Code {
  33. option allow_alias = true;
  34. // There is no error.
  35. CODE_UNSPECIFIED = 0;
  36. // There is no error.
  37. OK = 0;
  38. // Indicates an internal server error.
  39. // Please DO NOT USE THIS ERROR CODE unless the root cause is truly unknown.
  40. INTERNAL_ERROR = 1;
  41. // One of the seed URLs is an App Engine URL but we cannot validate the scan
  42. // settings due to an App Engine API backend error.
  43. APPENGINE_API_BACKEND_ERROR = 2;
  44. // One of the seed URLs is an App Engine URL but we cannot access the
  45. // App Engine API to validate scan settings.
  46. APPENGINE_API_NOT_ACCESSIBLE = 3;
  47. // One of the seed URLs is an App Engine URL but the Default Host of the
  48. // App Engine is not set.
  49. APPENGINE_DEFAULT_HOST_MISSING = 4;
  50. // Google corporate accounts can not be used for scanning.
  51. CANNOT_USE_GOOGLE_COM_ACCOUNT = 6;
  52. // The account of the scan creator can not be used for scanning.
  53. CANNOT_USE_OWNER_ACCOUNT = 7;
  54. // This scan targets Compute Engine, but we cannot validate scan settings
  55. // due to a Compute Engine API backend error.
  56. COMPUTE_API_BACKEND_ERROR = 8;
  57. // This scan targets Compute Engine, but we cannot access the Compute Engine
  58. // API to validate the scan settings.
  59. COMPUTE_API_NOT_ACCESSIBLE = 9;
  60. // The Custom Login URL does not belong to the current project.
  61. CUSTOM_LOGIN_URL_DOES_NOT_BELONG_TO_CURRENT_PROJECT = 10;
  62. // The Custom Login URL is malformed (can not be parsed).
  63. CUSTOM_LOGIN_URL_MALFORMED = 11;
  64. // The Custom Login URL is mapped to a non-routable IP address in DNS.
  65. CUSTOM_LOGIN_URL_MAPPED_TO_NON_ROUTABLE_ADDRESS = 12;
  66. // The Custom Login URL is mapped to an IP address which is not reserved for
  67. // the current project.
  68. CUSTOM_LOGIN_URL_MAPPED_TO_UNRESERVED_ADDRESS = 13;
  69. // The Custom Login URL has a non-routable IP address.
  70. CUSTOM_LOGIN_URL_HAS_NON_ROUTABLE_IP_ADDRESS = 14;
  71. // The Custom Login URL has an IP address which is not reserved for the
  72. // current project.
  73. CUSTOM_LOGIN_URL_HAS_UNRESERVED_IP_ADDRESS = 15;
  74. // Another scan with the same name (case-sensitive) already exists.
  75. DUPLICATE_SCAN_NAME = 16;
  76. // A field is set to an invalid value.
  77. INVALID_FIELD_VALUE = 18;
  78. // There was an error trying to authenticate to the scan target.
  79. FAILED_TO_AUTHENTICATE_TO_TARGET = 19;
  80. // Finding type value is not specified in the list findings request.
  81. FINDING_TYPE_UNSPECIFIED = 20;
  82. // Scan targets Compute Engine, yet current project was not whitelisted for
  83. // Google Compute Engine Scanning Alpha access.
  84. FORBIDDEN_TO_SCAN_COMPUTE = 21;
  85. // User tries to update managed scan
  86. FORBIDDEN_UPDATE_TO_MANAGED_SCAN = 43;
  87. // The supplied filter is malformed. For example, it can not be parsed, does
  88. // not have a filter type in expression, or the same filter type appears
  89. // more than once.
  90. MALFORMED_FILTER = 22;
  91. // The supplied resource name is malformed (can not be parsed).
  92. MALFORMED_RESOURCE_NAME = 23;
  93. // The current project is not in an active state.
  94. PROJECT_INACTIVE = 24;
  95. // A required field is not set.
  96. REQUIRED_FIELD = 25;
  97. // Project id, scanconfig id, scanrun id, or finding id are not consistent
  98. // with each other in resource name.
  99. RESOURCE_NAME_INCONSISTENT = 26;
  100. // The scan being requested to start is already running.
  101. SCAN_ALREADY_RUNNING = 27;
  102. // The scan that was requested to be stopped is not running.
  103. SCAN_NOT_RUNNING = 28;
  104. // One of the seed URLs does not belong to the current project.
  105. SEED_URL_DOES_NOT_BELONG_TO_CURRENT_PROJECT = 29;
  106. // One of the seed URLs is malformed (can not be parsed).
  107. SEED_URL_MALFORMED = 30;
  108. // One of the seed URLs is mapped to a non-routable IP address in DNS.
  109. SEED_URL_MAPPED_TO_NON_ROUTABLE_ADDRESS = 31;
  110. // One of the seed URLs is mapped to an IP address which is not reserved
  111. // for the current project.
  112. SEED_URL_MAPPED_TO_UNRESERVED_ADDRESS = 32;
  113. // One of the seed URLs has on-routable IP address.
  114. SEED_URL_HAS_NON_ROUTABLE_IP_ADDRESS = 33;
  115. // One of the seed URLs has an IP address that is not reserved
  116. // for the current project.
  117. SEED_URL_HAS_UNRESERVED_IP_ADDRESS = 35;
  118. // The Cloud Security Scanner service account is not configured under the
  119. // project.
  120. SERVICE_ACCOUNT_NOT_CONFIGURED = 36;
  121. // A project has reached the maximum number of scans.
  122. TOO_MANY_SCANS = 37;
  123. // Resolving the details of the current project fails.
  124. UNABLE_TO_RESOLVE_PROJECT_INFO = 38;
  125. // One or more blacklist patterns were in the wrong format.
  126. UNSUPPORTED_BLACKLIST_PATTERN_FORMAT = 39;
  127. // The supplied filter is not supported.
  128. UNSUPPORTED_FILTER = 40;
  129. // The supplied finding type is not supported. For example, we do not
  130. // provide findings of the given finding type.
  131. UNSUPPORTED_FINDING_TYPE = 41;
  132. // The URL scheme of one or more of the supplied URLs is not supported.
  133. UNSUPPORTED_URL_SCHEME = 42;
  134. }
  135. // Indicates the reason code for a configuration failure.
  136. Code code = 1;
  137. // Indicates the full name of the ScanConfig field that triggers this error,
  138. // for example "scan_config.max_qps". This field is provided for
  139. // troubleshooting purposes only and its actual value can change in the
  140. // future.
  141. string field_name = 2;
  142. }