securitycenter_settings_service.proto 25 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650
  1. // Copyright 2020 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. syntax = "proto3";
  15. package google.cloud.securitycenter.settings.v1beta1;
  16. import "google/api/annotations.proto";
  17. import "google/api/client.proto";
  18. import "google/api/field_behavior.proto";
  19. import "google/api/resource.proto";
  20. import "google/cloud/securitycenter/settings/v1beta1/component_settings.proto";
  21. import "google/cloud/securitycenter/settings/v1beta1/detector.proto";
  22. import "google/cloud/securitycenter/settings/v1beta1/settings.proto";
  23. import "google/protobuf/empty.proto";
  24. import "google/protobuf/field_mask.proto";
  25. option cc_enable_arenas = true;
  26. option csharp_namespace = "Google.Cloud.SecurityCenter.Settings.V1Beta1";
  27. option go_package = "google.golang.org/genproto/googleapis/cloud/securitycenter/settings/v1beta1;settings";
  28. option java_multiple_files = true;
  29. option java_outer_classname = "SettingsServiceProto";
  30. option java_package = "com.google.cloud.securitycenter.settings.v1beta1";
  31. option php_namespace = "Google\\Cloud\\SecurityCenter\\Settings\\V1beta1";
  32. option ruby_package = "Google::Cloud::SecurityCenter::Settings::V1beta1";
  33. // ## API Overview
  34. //
  35. // The SecurityCenterSettingsService is a sub-api of
  36. // `securitycenter.googleapis.com`. The service provides methods to manage
  37. // Security Center Settings, and Component Settings for GCP organizations,
  38. // folders, projects, and clusters.
  39. service SecurityCenterSettingsService {
  40. option (google.api.default_host) = "securitycenter.googleapis.com";
  41. option (google.api.oauth_scopes) = "https://www.googleapis.com/auth/cloud-platform";
  42. // Retrieves the organizations service account, if it exists, otherwise it
  43. // creates the organization service account. This API is idempotent and
  44. // will only create a service account once. On subsequent calls it will
  45. // return the previously created service account. SHA, SCC and CTD Infra
  46. // Automation will use this SA. This SA will not have any permissions when
  47. // created. The UI will provision this via IAM or the user will using
  48. // their own internal process. This API only creates SAs on the organization.
  49. // Folders are not supported and projects will use per-project SAs associated
  50. // with APIs enabled on a project. This API will be called by the UX
  51. // onboarding workflow.
  52. rpc GetServiceAccount(GetServiceAccountRequest) returns (ServiceAccount) {
  53. option (google.api.http) = {
  54. get: "/settings/v1beta1/{name=organizations/*/serviceAccount}"
  55. };
  56. option (google.api.method_signature) = "name";
  57. }
  58. // Gets the Settings.
  59. rpc GetSettings(GetSettingsRequest) returns (Settings) {
  60. option (google.api.http) = {
  61. get: "/settings/v1beta1/{name=organizations/*/settings}"
  62. additional_bindings {
  63. get: "/settings/v1beta1/{name=folders/*/settings}"
  64. }
  65. additional_bindings {
  66. get: "/settings/v1beta1/{name=projects/*/settings}"
  67. }
  68. additional_bindings {
  69. get: "/settings/v1beta1/{name=projects/*/locations/*/clusters/*/settings}"
  70. }
  71. additional_bindings {
  72. get: "/settings/v1beta1/{name=projects/*/regions/*/clusters/*/settings}"
  73. }
  74. additional_bindings {
  75. get: "/settings/v1beta1/{name=projects/*/zones/*/clusters/*/settings}"
  76. }
  77. };
  78. option (google.api.method_signature) = "name";
  79. }
  80. // Updates the Settings.
  81. rpc UpdateSettings(UpdateSettingsRequest) returns (Settings) {
  82. option (google.api.http) = {
  83. patch: "/settings/v1beta1/{settings.name=organizations/*/settings}"
  84. body: "settings"
  85. additional_bindings {
  86. patch: "/settings/v1beta1/{settings.name=folders/*/settings}"
  87. body: "settings"
  88. }
  89. additional_bindings {
  90. patch: "/settings/v1beta1/{settings.name=projects/*/settings}"
  91. body: "settings"
  92. }
  93. additional_bindings {
  94. patch: "/settings/v1beta1/{settings.name=projects/*/locations/*/clusters/*/settings}"
  95. body: "settings"
  96. }
  97. additional_bindings {
  98. patch: "/settings/v1beta1/{settings.name=projects/*/regions/*/clusters/*/settings}"
  99. body: "settings"
  100. }
  101. additional_bindings {
  102. patch: "/settings/v1beta1/{settings.name=projects/*/zones/*/clusters/*/settings}"
  103. body: "settings"
  104. }
  105. };
  106. option (google.api.method_signature) = "settings,update_mask";
  107. }
  108. // Reset the organization, folder or project's settings and return
  109. // the settings of just that resource to the default.
  110. //
  111. // Settings are present at the organization, folder, project, and cluster
  112. // levels. Using Reset on a sub-organization level will remove that resource's
  113. // override and result in the parent's settings being used (eg: if Reset on a
  114. // cluster, project settings will be used).
  115. //
  116. // Using Reset on organization will remove the override that was set and
  117. // result in default settings being used.
  118. rpc ResetSettings(ResetSettingsRequest) returns (google.protobuf.Empty) {
  119. option (google.api.http) = {
  120. post: "/settings/v1beta1/{name=organizations/*/settings}:reset"
  121. body: "*"
  122. additional_bindings {
  123. post: "/settings/v1beta1/{name=folders/*/settings}:reset"
  124. body: "*"
  125. }
  126. additional_bindings {
  127. post: "/settings/v1beta1/{name=projects/*/settings}:reset"
  128. body: "*"
  129. }
  130. additional_bindings {
  131. post: "/settings/v1beta1/{name=projects/*/locations/*/clusters/*/settings}:reset"
  132. body: "*"
  133. }
  134. additional_bindings {
  135. post: "/settings/v1beta1/{name=projects/*/regions/*/clusters/*/settings}:reset"
  136. body: "*"
  137. }
  138. additional_bindings {
  139. post: "/settings/v1beta1/{name=projects/*/zones/*/clusters/*/settings}:reset"
  140. body: "*"
  141. }
  142. };
  143. }
  144. // Gets a list of settings.
  145. rpc BatchGetSettings(BatchGetSettingsRequest) returns (BatchGetSettingsResponse) {
  146. option (google.api.http) = {
  147. get: "/settings/v1beta1/{parent=organizations/*}/settings:batchGet"
  148. };
  149. }
  150. // CalculateEffectiveSettings looks up all of the Security Center
  151. // Settings resources in the GCP resource hierarchy, and calculates the
  152. // effective settings on that resource by applying the following rules:
  153. // * Settings provided closer to the target resource take precedence over
  154. // those further away (e.g. folder will override organization level
  155. // settings).
  156. // * Product defaults can be overridden at org, folder, project, and cluster
  157. // levels.
  158. // * Detectors will be filtered out if they belong to a billing tier the
  159. // customer
  160. // has not configured.
  161. rpc CalculateEffectiveSettings(CalculateEffectiveSettingsRequest) returns (Settings) {
  162. option (google.api.http) = {
  163. get: "/settings/v1beta1/{name=organizations/*/effectiveSettings}:calculate"
  164. additional_bindings {
  165. get: "/settings/v1beta1/{name=folders/*/effectiveSettings}:calculate"
  166. }
  167. additional_bindings {
  168. get: "/settings/v1beta1/{name=projects/*/effectiveSettings}:calculate"
  169. }
  170. additional_bindings {
  171. get: "/settings/v1beta1/{name=projects/*/locations/*/clusters/*/effectiveSettings}:calculate"
  172. }
  173. additional_bindings {
  174. get: "/settings/v1beta1/{name=projects/*/regions/*/clusters/*/effectiveSettings}:calculate"
  175. }
  176. additional_bindings {
  177. get: "/settings/v1beta1/{name=projects/*/zones/*/clusters/*/effectiveSettings}:calculate"
  178. }
  179. };
  180. option (google.api.method_signature) = "name";
  181. }
  182. // Gets a list of effective settings.
  183. rpc BatchCalculateEffectiveSettings(BatchCalculateEffectiveSettingsRequest) returns (BatchCalculateEffectiveSettingsResponse) {
  184. option (google.api.http) = {
  185. post: "/settings/v1beta1/{parent=organizations/*}/effectiveSettings:batchCalculate"
  186. body: "*"
  187. };
  188. }
  189. // Gets the Component Settings.
  190. rpc GetComponentSettings(GetComponentSettingsRequest) returns (ComponentSettings) {
  191. option (google.api.http) = {
  192. get: "/settings/v1beta1/{name=organizations/*/components/*/settings}"
  193. additional_bindings {
  194. get: "/settings/v1beta1/{name=folders/*/components/*/settings}"
  195. }
  196. additional_bindings {
  197. get: "/settings/v1beta1/{name=projects/*/components/*/settings}"
  198. }
  199. additional_bindings {
  200. get: "/settings/v1beta1/{name=projects/*/locations/*/clusters/*/components/*/settings}"
  201. }
  202. additional_bindings {
  203. get: "/settings/v1beta1/{name=projects/*/regions/*/clusters/*/components/*/settings}"
  204. }
  205. additional_bindings {
  206. get: "/settings/v1beta1/{name=projects/*/zones/*/clusters/*/components/*/settings}"
  207. }
  208. };
  209. option (google.api.method_signature) = "name";
  210. }
  211. // Updates the Component Settings.
  212. rpc UpdateComponentSettings(UpdateComponentSettingsRequest) returns (ComponentSettings) {
  213. option (google.api.http) = {
  214. patch: "/settings/v1beta1/{component_settings.name=organizations/*/components/*/settings}"
  215. body: "component_settings"
  216. additional_bindings {
  217. patch: "/settings/v1beta1/{component_settings.name=folders/*/components/*/settings}"
  218. body: "component_settings"
  219. }
  220. additional_bindings {
  221. patch: "/settings/v1beta1/{component_settings.name=projects/*/components/*/settings}"
  222. body: "component_settings"
  223. }
  224. additional_bindings {
  225. patch: "/settings/v1beta1/{component_settings.name=projects/*/locations/*/clusters/*/components/*/settings}"
  226. body: "component_settings"
  227. }
  228. additional_bindings {
  229. patch: "/settings/v1beta1/{component_settings.name=projects/*/regions/*/clusters/*/components/*/settings}"
  230. body: "component_settings"
  231. }
  232. additional_bindings {
  233. patch: "/settings/v1beta1/{component_settings.name=projects/*/zones/*/clusters/*/components/*/settings}"
  234. body: "component_settings"
  235. }
  236. };
  237. option (google.api.method_signature) = "component_settings,update_mask";
  238. }
  239. // Reset the organization, folder or project's component settings and return
  240. // the settings to the default. Settings are present at the
  241. // organization, folder and project levels. Using Reset for a folder or
  242. // project will remove the override that was set and result in the
  243. // organization-level settings being used.
  244. rpc ResetComponentSettings(ResetComponentSettingsRequest) returns (google.protobuf.Empty) {
  245. option (google.api.http) = {
  246. post: "/settings/v1beta1/{name=organizations/*/components/*/settings}:reset"
  247. body: "*"
  248. additional_bindings {
  249. post: "/settings/v1beta1/{name=folders/*/components/*/settings}:reset"
  250. body: "*"
  251. }
  252. additional_bindings {
  253. post: "/settings/v1beta1/{name=projects/*/components/*/settings}:reset"
  254. body: "*"
  255. }
  256. additional_bindings {
  257. post: "/settings/v1beta1/{name=projects/*/locations/*/clusters/*/components/*/settings}:reset"
  258. body: "*"
  259. }
  260. additional_bindings {
  261. post: "/settings/v1beta1/{name=projects/*/regions/*/clusters/*/components/*/settings}:reset"
  262. body: "*"
  263. }
  264. additional_bindings {
  265. post: "/settings/v1beta1/{name=projects/*/zones/*/clusters/*/components/*/settings}:reset"
  266. body: "*"
  267. }
  268. };
  269. }
  270. // Gets the Effective Component Settings.
  271. rpc CalculateEffectiveComponentSettings(CalculateEffectiveComponentSettingsRequest) returns (ComponentSettings) {
  272. option (google.api.http) = {
  273. get: "/settings/v1beta1/{name=organizations/*/components/*/effectiveSettings}:calculate"
  274. additional_bindings {
  275. get: "/settings/v1beta1/{name=folders/*/components/*/effectiveSettings}:calculate"
  276. }
  277. additional_bindings {
  278. get: "/settings/v1beta1/{name=projects/*/components/*/effectiveSettings}:calculate"
  279. }
  280. additional_bindings {
  281. get: "/settings/v1beta1/{name=projects/*/locations/*/clusters/*/components/*/effectiveSettings}:calculate"
  282. }
  283. additional_bindings {
  284. get: "/settings/v1beta1/{name=projects/*/regions/*/clusters/*/components/*/effectiveSettings}:calculate"
  285. }
  286. additional_bindings {
  287. get: "/settings/v1beta1/{name=projects/*/zones/*/clusters/*/components/*/effectiveSettings}:calculate"
  288. }
  289. };
  290. option (google.api.method_signature) = "name";
  291. }
  292. // Retrieves an unordered list of available detectors.
  293. rpc ListDetectors(ListDetectorsRequest) returns (ListDetectorsResponse) {
  294. option (google.api.http) = {
  295. get: "/settings/v1beta1/{parent=organizations/*}/detectors"
  296. };
  297. option (google.api.method_signature) = "parent";
  298. }
  299. // Retrieves an unordered list of available SCC components.
  300. rpc ListComponents(ListComponentsRequest) returns (ListComponentsResponse) {
  301. option (google.api.http) = {
  302. get: "/settings/v1beta1/{parent=organizations/*}/components"
  303. };
  304. option (google.api.method_signature) = "parent";
  305. }
  306. }
  307. // Request message for GetServiceAccount.
  308. message GetServiceAccountRequest {
  309. // Required. The relative resource name of the service account resource.
  310. // Format:
  311. // * `organizations/{organization}/serviceAccount`
  312. string name = 1 [
  313. (google.api.field_behavior) = REQUIRED,
  314. (google.api.resource_reference) = {
  315. type: "securitycenter.googleapis.com/ServiceAccount"
  316. }
  317. ];
  318. }
  319. // An organization-level service account to be used by threat detection
  320. // components.
  321. message ServiceAccount {
  322. option (google.api.resource) = {
  323. type: "securitycenter.googleapis.com/ServiceAccount"
  324. pattern: "organizations/{organization}/serviceAccount"
  325. };
  326. // The relative resource name of the service account resource.
  327. // Format:
  328. // * `organizations/{organization}/serviceAccount`
  329. string name = 1;
  330. // Security Center managed service account for the organization
  331. // example service-org-1234@scc.iam.gserviceaccount.com
  332. // This service_account will be stored in the ComponentSettings field for the
  333. // SCC, SHA, and Infra Automation components.
  334. string service_account = 2;
  335. }
  336. // Request message for GetSettings.
  337. message GetSettingsRequest {
  338. // Required. The name of the settings to retrieve.
  339. // Formats:
  340. // * `organizations/{organization}/settings`
  341. // * `folders/{folder}/settings`
  342. // * `projects/{project}/settings`
  343. // * `projects/{project}/locations/{location}/clusters/{cluster}/settings`
  344. // * `projects/{project}/regions/{region}/clusters/{cluster}/settings`
  345. // * `projects/{project}/zones/{zone}/clusters/{cluster}/settings`
  346. string name = 1 [
  347. (google.api.field_behavior) = REQUIRED,
  348. (google.api.resource_reference) = {
  349. type: "securitycenter.googleapis.com/Settings"
  350. }
  351. ];
  352. }
  353. // Request message for UpdateSettings.
  354. message UpdateSettingsRequest {
  355. // Required. The settings to update.
  356. //
  357. // The settings' `name` field is used to identify the settings to be updated.
  358. // Formats:
  359. // * `organizations/{organization}/settings`
  360. // * `folders/{folder}/settings`
  361. // * `projects/{project}/settings`
  362. // * `projects/{project}/locations/{location}/clusters/{cluster}/settings`
  363. // * `projects/{project}/regions/{region}/clusters/{cluster}/settings`
  364. // * `projects/{project}/zones/{zone}/clusters/{cluster}/settings`
  365. Settings settings = 1 [(google.api.field_behavior) = REQUIRED];
  366. // The list of fields to be updated on the settings.
  367. google.protobuf.FieldMask update_mask = 2;
  368. }
  369. // Request message for ResetSettings.
  370. message ResetSettingsRequest {
  371. // Required. The name of the settings to reset.
  372. // Formats:
  373. // * `organizations/{organization}/settings`
  374. // * `folders/{folder}/settings`
  375. // * `projects/{project}/settings`
  376. // * `projects/{project}/locations/{location}/clusters/{cluster}/settings`
  377. // * `projects/{project}/regions/{region}/clusters/{cluster}/settings`
  378. // * `projects/{project}/zones/{zone}/clusters/{cluster}/settings`
  379. string name = 1 [
  380. (google.api.field_behavior) = REQUIRED,
  381. (google.api.resource_reference) = {
  382. type: "securitycenter.googleapis.com/Settings"
  383. }
  384. ];
  385. // A fingerprint used for optimistic concurrency. If none is provided,
  386. // then the existing settings will be blindly overwritten.
  387. string etag = 2;
  388. }
  389. // Request message for BatchGetSettings.
  390. message BatchGetSettingsRequest {
  391. // Required. The relative resource name of the organization shared by all of the
  392. // settings being retrieved.
  393. // Format:
  394. // * `organizations/{organization}`
  395. string parent = 1 [
  396. (google.api.field_behavior) = REQUIRED,
  397. (google.api.resource_reference) = {
  398. type: "cloudresourcemanager.googleapis.com/Organization"
  399. }
  400. ];
  401. // The names of the settings to retrieve.
  402. // A maximum of 1000 settings can be retrieved in a batch.
  403. // Formats:
  404. // * `organizations/{organization}/settings`
  405. // * `folders/{folder}/settings`
  406. // * `projects/{project}/settings`
  407. // * `projects/{project}/locations/{location}/clusters/{cluster}/settings`
  408. // * `projects/{project}/regions/{region}/clusters/{cluster}/settings`
  409. // * `projects/{project}/zones/{zone}/clusters/{cluster}/settings`
  410. repeated string names = 2;
  411. }
  412. // Response message for BatchGetSettings.
  413. message BatchGetSettingsResponse {
  414. // Settings requested.
  415. repeated Settings settings = 1;
  416. }
  417. // Request message for CalculateEffectiveSettings.
  418. message CalculateEffectiveSettingsRequest {
  419. // Required. The name of the effective settings to retrieve.
  420. // Formats:
  421. // * `organizations/{organization}/effectiveSettings`
  422. // * `folders/{folder}/effectiveSettings`
  423. // * `projects/{project}/effectiveSettings`
  424. // * `projects/{project}/locations/{location}/clusters/{cluster}/effectiveSettings`
  425. // * `projects/{project}/regions/{region}/clusters/{cluster}/effectiveSettings`
  426. // * `projects/{project}/zones/{zone}/clusters/{cluster}/effectiveSettings`
  427. string name = 1 [
  428. (google.api.field_behavior) = REQUIRED,
  429. (google.api.resource_reference) = {
  430. type: "securitycenter.googleapis.com/Settings"
  431. }
  432. ];
  433. }
  434. // Request message for BatchGetEffectiveSettings.
  435. message BatchCalculateEffectiveSettingsRequest {
  436. // Required. The relative resource name of the organization shared by all of the
  437. // settings being retrieved.
  438. // Format:
  439. // * `organizations/{organization}`
  440. string parent = 1 [
  441. (google.api.field_behavior) = REQUIRED,
  442. (google.api.resource_reference) = {
  443. type: "cloudresourcemanager.googleapis.com/Organization"
  444. }
  445. ];
  446. // The requests specifying the effective settings to retrieve.
  447. // A maximum of 1000 effective settings can be retrieved in a batch.
  448. repeated CalculateEffectiveSettingsRequest requests = 2;
  449. }
  450. // Response message for BatchGetEffectiveSettings.
  451. message BatchCalculateEffectiveSettingsResponse {
  452. // Settings requested.
  453. repeated Settings settings = 1;
  454. }
  455. // Request message for GetComponentSettings.
  456. message GetComponentSettingsRequest {
  457. // Required. The component settings to retrieve.
  458. //
  459. // Formats:
  460. // * `organizations/{organization}/components/{component}/settings`
  461. // * `folders/{folder}/components/{component}/settings`
  462. // * `projects/{project}/components/{component}/settings`
  463. // * `projects/{project}/locations/{location}/clusters/{cluster}/components/{component}/settings`
  464. // * `projects/{project}/regions/{region}/clusters/{cluster}/components/{component}/settings`
  465. // * `projects/{project}/zones/{zone}/clusters/{cluster}/components/{component}/settings`
  466. string name = 1 [
  467. (google.api.field_behavior) = REQUIRED,
  468. (google.api.resource_reference) = {
  469. type: "securitycenter.googleapis.com/ComponentSettings"
  470. }
  471. ];
  472. }
  473. // Request message for UpdateComponentSettings.
  474. message UpdateComponentSettingsRequest {
  475. // Required. The component settings to update.
  476. //
  477. // The component settings' `name` field is used to identify the component
  478. // settings to be updated. Formats:
  479. // * `organizations/{organization}/components/{component}/settings`
  480. // * `folders/{folder}/components/{component}/settings`
  481. // * `projects/{project}/components/{component}/settings`
  482. // * `projects/{project}/locations/{location}/clusters/{cluster}/components/{component}/settings`
  483. // * `projects/{project}/regions/{region}/clusters/{cluster}/components/{component}/settings`
  484. // * `projects/{project}/zones/{zone}/clusters/{cluster}/components/{component}/settings`
  485. ComponentSettings component_settings = 1 [(google.api.field_behavior) = REQUIRED];
  486. // The list of fields to be updated on the component settings resource.
  487. google.protobuf.FieldMask update_mask = 2;
  488. }
  489. // Request message for ResetComponentSettings.
  490. message ResetComponentSettingsRequest {
  491. // Required. The component settings to reset.
  492. //
  493. // Formats:
  494. // * `organizations/{organization}/components/{component}/settings`
  495. // * `folders/{folder}/components/{component}/settings`
  496. // * `projects/{project}/components/{component}/settings`
  497. // * `projects/{project}/locations/{location}/clusters/{cluster}/components/{component}/settings`
  498. // * `projects/{project}/regions/{region}/clusters/{cluster}/components/{component}/settings`
  499. // * `projects/{project}/zones/{zone}/clusters/{cluster}/components/{component}/settings`
  500. string name = 1 [
  501. (google.api.field_behavior) = REQUIRED,
  502. (google.api.resource_reference) = {
  503. type: "securitycenter.googleapis.com/ComponentSettings"
  504. }
  505. ];
  506. // An fingerprint used for optimistic concurrency. If none is provided,
  507. // then the existing settings will be blindly overwritten.
  508. string etag = 2;
  509. }
  510. // Request message for CalculateEffectiveComponentSettings.
  511. message CalculateEffectiveComponentSettingsRequest {
  512. // Required. The effective component settings to retrieve.
  513. //
  514. // Formats:
  515. // * `organizations/{organization}/components/{component}/settings`
  516. // * `folders/{folder}/components/{component}/settings`
  517. // * `projects/{project}/components/{component}/settings`
  518. // * `projects/{project}/locations/{location}/clusters/{cluster}/components/{component}/settings`
  519. // * `projects/{project}/regions/{region}/clusters/{cluster}/components/{component}/settings`
  520. // * `projects/{project}/zones/{zone}/clusters/{cluster}/components/{component}/settings`
  521. string name = 1 [
  522. (google.api.field_behavior) = REQUIRED,
  523. (google.api.resource_reference) = {
  524. type: "securitycenter.googleapis.com/ComponentSettings"
  525. }
  526. ];
  527. }
  528. // Request message for ListDetectors.
  529. message ListDetectorsRequest {
  530. // Required. The parent, which owns this collection of detectors.
  531. // Format:
  532. // * `organizations/{organization}`
  533. string parent = 1 [
  534. (google.api.field_behavior) = REQUIRED,
  535. (google.api.resource_reference) = {
  536. type: "cloudresourcemanager.googleapis.com/Organization"
  537. }
  538. ];
  539. // Filters to apply on the response. Filters can be applied on:
  540. // * components
  541. // * labels
  542. // * billing tiers
  543. //
  544. // Component filters will retrieve only detectors for the components
  545. // specified. Label filters will retrieve only detectors that match one of the
  546. // labels specified. Billing tier filters will retrieve only detectors for
  547. // that billing tier.
  548. //
  549. // The filters
  550. string filter = 2;
  551. // The maximum number of detectors to return. The service may return fewer
  552. // than this value. If unspecified, at most 100 detectors will be returned.
  553. // The maximum value is 1000; values above 1000 will be coerced to 1000.
  554. int32 page_size = 3;
  555. // A page token, received from a previous `ListDetectors` call.
  556. // Provide this to retrieve the subsequent page.
  557. //
  558. // When paginating, all other parameters provided to `ListDetectors` must
  559. // match the call that provided the page token.
  560. string page_token = 4;
  561. }
  562. // Response message for ListDetectors.
  563. message ListDetectorsResponse {
  564. // The detectors from the specified organization.
  565. repeated Detector detectors = 1;
  566. // A token that can be sent as `page_token` to retrieve the next page.
  567. // If this field is omitted, there are no subsequent pages.
  568. string next_page_token = 2;
  569. }
  570. // Request message for ListComponents.
  571. message ListComponentsRequest {
  572. // Required. The parent, which owns this collection of components.
  573. // Format:
  574. // * `organizations/{organization}`
  575. string parent = 1 [
  576. (google.api.field_behavior) = REQUIRED,
  577. (google.api.resource_reference) = {
  578. type: "cloudresourcemanager.googleapis.com/Organization"
  579. }
  580. ];
  581. // The maximum number of components to return. The service may return fewer
  582. // than this value. If unspecified, at most 100 components will be returned.
  583. // The maximum value is 1000; values above 1000 will be coerced to 1000.
  584. int32 page_size = 2;
  585. // A page token, received from a previous `ListComponents` call.
  586. // Provide this to retrieve the subsequent page.
  587. //
  588. // When paginating, all other parameters provided to `ListComponents` must
  589. // match the call that provided the page token.
  590. string page_token = 3;
  591. }
  592. // Response message for ListComponents.
  593. message ListComponentsResponse {
  594. // The components from the specified organization.
  595. repeated string components = 1;
  596. // A token that can be sent as `page_token` to retrieve the next page.
  597. // If this field is omitted, there are no subsequent pages.
  598. string next_page_token = 2;
  599. }